Planetfall 2.0 (apparently)

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

User avatar
Cholmondely
Archivist
Archivist
Posts: 6092
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Planetfall 2.0 (apparently)

Post by Cholmondely »

phkb wrote: Tue Jun 24, 2025 10:57 pm
Bicorn wrote: Tue Jun 24, 2025 6:50 pm
Why are the markets all disabled by default, by the way?
I couldn't work out a "best" default, given these markets are so close to the main station. My thoughts, if I'm pushed reluctantly into lore, are that the main station is where cargo is offered to traders. Planetary markets are off limits by nature of the GalCop agreement each system has signed. (No doubt someone will be along shortly to tear my lore explanation to shreds, but that's par for the course!).
Very close, yes. But also a major pain to get to. It is the one dangerous bit of flying in Oolite (docking is a doddle, comparatively).

So, yes, I can see the argument that GalCop will try and restrict interstellar trade just to the station, so that they can cream off some credits and supplement the stipend paid by the local governments.

But even if markets can be found downplanet, the danger in landing combined with the much higher maintenance costs will prevent most pilots from accessing the planet-side markets. And I've not yet noticed any ships making their way to the planet-side star-ports. Unlike the bazillion or so trundling merrily between the witchpoint beacon and the main orbital.

phkb wrote: Tue Jun 24, 2025 10:57 pm
Bicorn wrote: Tue Jun 24, 2025 6:50 pm
Incidentally, is there a way to suppress automatically going from yellow to red alert when close enough to the planet? The WOOP WOOP and ColuberHUD switching to combat configuration is a little distracting.
I'm not sure. The fact is, you are perilously close to the surface by the time the docking sequence kicks is. If you don't dock (for whatever reason), you are is serious danger. But I'll have a look and see if I can suppress it somewhat.
I think that it should be there, rather than suppressed. Landing is incredibly dangerous and is where most accidents will happen. And it damages your ship.
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
Bicorn
Poor
Poor
Posts: 7
Joined: Wed Jun 18, 2025 8:47 am

Re: Planetfall 2.0 (apparently)

Post by Bicorn »

phkb wrote: Tue Jun 24, 2025 10:57 pm
A scaling factor will be in the next version.
That's good to hear!
phkb wrote: Tue Jun 24, 2025 10:57 pm
Bicorn wrote: Tue Jun 24, 2025 6:50 pm
For the on-planet markets, I notice the explanation for what the various settings do appears to be missing from the wiki. It's on the table of contents, but the links lead nowhere.
There are so many options, I thought it best to hide it all by default, otherwise you'd spend ages paging through all the info. In the "Options" section (in the body, not in the contents), there should be a link on the right labelled "Show me everything". That will unhide the options. Click the "Turn it off! Turn if off!" link to hide them again.
Ahh, somehow I missed that link entirely.
phkb wrote: Tue Jun 24, 2025 10:57 pm
And thanks for the feedback! Super helpful!
You're quite welcome! The OXP is a great addition to Oolite, and I think has a lot of potential for further development.
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5190
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Planetfall 2.0 (apparently)

Post by phkb »

OK, PlanetFall2 updates incoming!
First, there's been a tweak to some of the images in the Resources pack, so that's been updated and bumped to version 1.1

Next, the main PlanetFall 2 pack. The short version of the update is:
- Added a "turbulence impact scale" option so the effect of turbulence can be scaled to taste.
- Allowed for blank entries in location overrides to switch to randomised location types and naming.
- Added ability to override the landing clouds, docks and overlays on a per-planet basis.
- Fixed issues when checking roles to determine the type of VFX to show for landing.
- Some code refactoring.

With the second item, see my reply a couple of posts back for an example of mixing and matching randomly generated items with pre-defined ones.

For the third item, here's a summary:
If you want to override the various images used for the landing VFX, do the following:

Code: Select all

this.startUpComplete = function() {
    // overriding the landing VFX images is done on a per-planet basis.
    // pick the planet for which you want to override images.
    // this this example, we are using the main planet
    var pl = system.mainPlanet;
    // if there's no main planet, just return at this point
    if (!pl) return;

    pl._pf2_landingImageOverrides = {
        clouds: {
            // this is the filename used for the "clouds" when descending to dock on the sunlit side of the planet
            normal: "normal_clouds.png",
            // this is the filename used for the "clouds" when descending to dock on the dark side of the planet
            night: "night_clouds.png"
        },
        dock: {
            // this is the filename used for the "dock" image used when descending to dock on the planet
            normal: "normal_clouds.png"
            // there is no "night" side docking pad image. docks are assumed to be well lit
        },
        overlay: {
            // this is the overlay to use on top of the landing image on the sunlit side of the planet
            normal: "normal_overlay.png",
            // this is the overlay to use on top of the landing image on the dark side of the planet
            night: "night_overlay.png"
        },
    };
}
Cloud and dock images should have dimensions of 1024x2048 px. Overlay images should be 2048x1024 px.

So, what this means is that it is now possible to change the cloud and dock images used when docking, and also control the overlay used on the arrival report screen. It doesn't make any of the ideas Cholly put forward happen, but it should now provide a means by which it *could* happen.

When it comes to those ideas, things like underwater locations, or cloud-based locations, that would require a full custom system build, with new landing images and what not. Don't know I have the scope to look at doing those yet, so if anyone else wants to have a go, checkout the "Creating Custom Systems" PDF file in the package, and shout out if you've got questions. The downside of allowing more and complete customisation, the more complicated the beast gets.
User avatar
Cholmondely
Archivist
Archivist
Posts: 6092
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Planetfall 2.0 (apparently)

Post by Cholmondely »

phkb wrote: Wed Jun 25, 2025 6:57 am
OK, PlanetFall2 updates incoming!
First, there's been a tweak to some of the images in the Resources pack, so that's been updated and bumped to version 1.1

Next, the main PlanetFall 2 pack. The short version of the update is:
- Added a "turbulence impact scale" option so the effect of turbulence can be scaled to taste.
- Allowed for blank entries in location overrides to switch to randomised location types and naming.
- Added ability to override the landing clouds, docks and overlays on a per-planet basis.
- Fixed issues when checking roles to determine the type of VFX to show for landing.
- Some code refactoring.

With the second item, see my reply a couple of posts back for an example of mixing and matching randomly generated items with pre-defined ones.

For the third item, here's a summary:
If you want to override the various images used for the landing VFX, do the following:

Code: Select all

this.startUpComplete = function() {
    // overriding the landing VFX images is done on a per-planet basis.
    // pick the planet for which you want to override images.
    // this this example, we are using the main planet
    var pl = system.mainPlanet;
    // if there's no main planet, just return at this point
    if (!pl) return;

    pl._pf2_landingImageOverrides = {
        clouds: {
            // this is the filename used for the "clouds" when descending to dock on the sunlit side of the planet
            normal: "normal_clouds.png",
            // this is the filename used for the "clouds" when descending to dock on the dark side of the planet
            night: "night_clouds.png"
        },
        dock: {
            // this is the filename used for the "dock" image used when descending to dock on the planet
            normal: "normal_clouds.png"
            // there is no "night" side docking pad image. docks are assumed to be well lit
        },
        overlay: {
            // this is the overlay to use on top of the landing image on the sunlit side of the planet
            normal: "normal_overlay.png",
            // this is the overlay to use on top of the landing image on the dark side of the planet
            night: "night_overlay.png"
        },
    };
}
Cloud and dock images should have dimensions of 1024x2048 px. Overlay images should be 2048x1024 px.

So, what this means is that it is now possible to change the cloud and dock images used when docking, and also control the overlay used on the arrival report screen. It doesn't make any of the ideas Cholly put forward happen, but it should now provide a means by which it *could* happen.

When it comes to those ideas, things like underwater locations, or cloud-based locations, that would require a full custom system build, with new landing images and what not. Don't know I have the scope to look at doing those yet, so if anyone else wants to have a go, checkout the "Creating Custom Systems" PDF file in the package, and shout out if you've got questions. The downside of allowing more and complete customisation, the more complicated the beast gets.
Thank you for this!

There are a couple of planet descriptions (Zaatxe, Beusrior...) mentioning severe storms - how would I work the massively increased turbulence into the game?
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5190
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Planetfall 2.0 (apparently)

Post by phkb »

How would you…
Aw, biscuits.
Um, yeah, looks like I might need to add some more options to allow for upscaling the turbulence effect. Next version.
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2763
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Re: Planetfall 2.0 (apparently)

Post by Wildeblood »

Bicorn wrote: Tue Jun 24, 2025 6:50 pm
Incidentally, is there a way to suppress automatically going from yellow to red alert when close enough to the planet? The WOOP WOOP and ColuberHUD switching to combat configuration is a little distracting.
If you're comfortable editing a javascript, and you know which script is causing it. Presumably, Coluber HUD.

There's a variable alertCondition, which will be an integer, 0-3 (0 = docked... 3 = red alert).

There are also Boolean variables to distinguish what's causing the red alert.

alertHostiles
alertAltitude

Look for a function called alertConditionChanged and insert a check for player.alertHostiles being true at the appropriate point.
"Must keep this response efficient to preserve remaining context."
Bicorn
Poor
Poor
Posts: 7
Joined: Wed Jun 18, 2025 8:47 am

Re: Planetfall 2.0 (apparently)

Post by Bicorn »

Wildeblood wrote: Wed Jun 25, 2025 10:48 am
Bicorn wrote: Tue Jun 24, 2025 6:50 pm
Incidentally, is there a way to suppress automatically going from yellow to red alert when close enough to the planet? The WOOP WOOP and ColuberHUD switching to combat configuration is a little distracting.
If you're comfortable editing a javascript, and you know which script is causing it. Presumably, Coluber HUD.

There's a variable alertCondition, which will be an integer, 0-3 (0 = docked... 3 = red alert).

There are also Boolean variables to distinguish what's causing the red alert.

alertHostiles
alertAltitude

Look for a function called alertConditionChanged and insert a check for player.alertHostiles being true at the appropriate point.
I poked around in ColuberHUD's files, and looks like the change in the HUD configuration is done in the plist rather than the scripting. The various bars are defined twice, one version shown during red alert and another otherwise.
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2763
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Re: Planetfall 2.0 (apparently)

Post by Wildeblood »

Bicorn wrote: Wed Jun 25, 2025 1:37 pm
I poked around in ColuberHUD's files, and looks like the change in the HUD configuration is done in the plist rather than the scripting. The various bars are defined twice, one version shown during red alert and another otherwise.
I beg your pardon. I was thinking of how we did things in the olden days. In that case, no you can't be specific to which type of red alerts cause the change. Sorry.
"Must keep this response efficient to preserve remaining context."
Bicorn
Poor
Poor
Posts: 7
Joined: Wed Jun 18, 2025 8:47 am

Re: Planetfall 2.0 (apparently)

Post by Bicorn »

phkb wrote: Wed Jun 25, 2025 6:57 am
OK, PlanetFall2 updates incoming!
Thanks for the update! I'll experiment with the turbulence scaling to see if I can find that sweet spot of noticeable enough to give a feeling of being in the atmosphere, but won't make my passengers spill their tea on themselves.
Bicorn
Poor
Poor
Posts: 7
Joined: Wed Jun 18, 2025 8:47 am

Re: Planetfall 2.0 (apparently)

Post by Bicorn »

Speaking of passengers, I think the Taxi Galactica OXP doesn't quite understand how Planetfall 2 handles on-planet locations; I just saw someone wanting to book a trip to the same planet they were boarding from, without specifying the landing site.
User avatar
Cholmondely
Archivist
Archivist
Posts: 6092
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Planetfall 2.0 (apparently)

Post by Cholmondely »

Bicorn wrote: Wed Jun 25, 2025 2:59 pm
Speaking of passengers, I think the Taxi Galactica OXP doesn't quite understand how Planetfall 2.0 handles on-planet locations; I just saw someone wanting to book a trip to the same planet they were boarding from, without specifying the landing site.
The only OXP which really uses Planetfall 2.0 is DGill's brand new version of Feudal States. It is possible that Littlebear's "The Assassins Guild Rebooted" does so too.

Littlebear's "The Galactic Almanac" interfaces with it. As do Lave.oxp, Riredi.oxp & Tianve.oxp. As will the imminently-to-be-published Famous Planets v.3.0.

Older OXPs such as Taxi Galactica & In-System Cargo Delivery (Stranger's World) etc all use the original Planetfall 1.0.

Sorry!



Taxi Galactica is Pleb's. Since he's just returned from the clutches of the Witchspace Lobster, you could try bugging him on the Taxi Galactica thread.

Tip: It helps to quote one of his posts as that ensures that he gets a "Notification" that he's been bugged!
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Cholmondely
Archivist
Archivist
Posts: 6092
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Planetfall 2.0 (apparently)

Post by Cholmondely »

Wildeblood wrote: Wed Jun 25, 2025 1:46 pm
Sorry.
So, if I understand you correctly, somebody with the knowledge could rejig the OXP to use Javascript to differentiate between the two. And thus not switch if one were at too low an altitude (and also not forgetting to comment out the original switchers ("alert_conditions=" ?) in the oxp plists).
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2763
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Re: Planetfall 2.0 (apparently)

Post by Wildeblood »

Cholmondely wrote: Wed Jun 25, 2025 6:46 pm
Wildeblood wrote: Wed Jun 25, 2025 1:46 pm
Sorry.
So, if I understand you correctly, somebody with the knowledge could rejig the OXP to use Javascript to differentiate between the two. And thus not switch if one were at too low an altitude (and also not forgetting to comment out the original switchers ("alert_conditions=" ?) in the oxp plists).
Yeah. I suppose. Bring your own equipment.plist - go back to the old way of guarding the dials (scanner is it?) with an equipment requirement, instead of "alert_conditions=" - the script is a single function, about 8 lines.

https://wiki.alioth.net/index.php/MilHUD_4000
"Must keep this response efficient to preserve remaining context."
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5190
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Planetfall 2.0 (apparently)

Post by phkb »

Bicorn wrote: Wed Jun 25, 2025 2:59 pm
I think the Taxi Galactica OXP doesn't quite understand how Planetfall 2 handles on-planet locations
Taxi Galactica takes passengers from one system to another.
In-System Taxi takes passengers from one system location to another, and is the one that is (currently) incompatible with PF2. But I've got a new version incoming.
Cholmondely wrote: Wed Jun 25, 2025 3:27 pm
In-System Cargo Delivery
This should be compatible with PF2, as I did some monkey patching to it to make it so. However, I might have got it wrong, so while I'm doing other things, if you can check if it works or not, and if not I'll circle back to it.

As for the issue with HUD's, I'm still looking into it, but I suspect Wildeblood's solution is the one that will work best (ie. making the red alert on low altitude hud elements dependent on some equipment etc).
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5190
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Planetfall 2.0 (apparently)

Post by phkb »

Version 2.19 should be in the manager shortly. In this version:
- Setting beacon range to zero will make all beacons visible all the time.
- Added ability to scale the maximum turbulence factor per planet.

For that last item, if you what to change the maximum turbulence factor for an individual planet, do the following:

Code: Select all

this.startUpComplete = function() {
    // this this example, we are using the main planet
    var pl = system.mainPlanet;
    // if there's no main planet, just return at this point
    if (!pl) return;

    // this would increase the default maximum turbulence factor by 10%
    pl._pf2_turbulence = {scaleMax: 1.1};
}
Post Reply