System statistics

General discussion for players of Oolite.

Moderators: another_commander, winston

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

Re: Lengthy planet descriptions

Post by Cholmondely »

Wildeblood wrote: Wed Apr 02, 2025 4:04 am
...Middlemap...
...regex...
?
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: 2948
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Revisions of "Oolite JavaScript Reference: SystemInfo"

Post by Wildeblood »

This was added to https://wiki.alioth.net/index.php/Oolit ... SystemInfo during development of Oolite 1.81:
Revision as of 20:36, 4 July 2015

Line 70:

=== <code>setProperty</code> ===

{{oolite-method-added|1.81}}

function '''setProperty'''(key : String, value: String, layer: Number [, manifest: String])

This lets you set properties with more control than provided by writing directly to <code>systemInfo.property</code>. <code>layer</code> is the layer from 0 to 3 that the change should be applied at, as in [[planetinfo.plist]]. Layer 2 is the default layer for Javascript-initiated changes, but 3 may be used for changes absolutely crucial for OXP functionality.
Almost three and a half years later, this change was made:

Revision as of 00:24, 16 November 2018

function '''setProperty'''(key : String, value: String, layer: Number [, manifest: String])
+
function '''setProperty'''(layer: Number, key : String, value: String [, manifest: String])

My question is, did the implementation of this method change, or was the wiki showing incorrect information for more than three years?
R.I.P. John Lodge, 1943-2025.
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 7192
Joined: Wed Feb 28, 2007 7:54 am

Re: System statistics

Post by another_commander »

layer has been the first parameter in this method since its entry into the codebase in October 2014. It looks like the wiki had it wrong for a while.

Edit: Also, key is named property in the code.
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2948
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Spurious Planetinfo.plist descriptions?

Post by Wildeblood »

Thank you, a_c.

Moving on to planetinfo.plist, and...

https://wiki.alioth.net/index.php/Planetinfo.plist mentions properties of:-
6.9 Percent Cloud
6.10 Percent Ice
6.11 Percent Land

But, Resources/Config/planetinfo.plist contains:-
cloud_fraction
no mention of ice
land_fraction

And, I can also see a polar_cloud_color, which isn't mentioned on the wiki page?
R.I.P. John Lodge, 1943-2025.
User avatar
Cholmondely
Archivist
Archivist
Posts: 6594
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Spurious Planetinfo.plist descriptions?

Post by Cholmondely »

Wildeblood wrote: Wed May 07, 2025 6:45 pm
Thank you, a_c.

Moving on to planetinfo.plist, and...

https://wiki.alioth.net/index.php/Planetinfo.plist mentions properties of:-
6.9 Percent Cloud
6.10 Percent Ice
6.11 Percent Land

But, Resources/Config/planetinfo.plist contains:-
cloud_fraction
no mention of ice
land_fraction

And, I can also see a polar_cloud_color, which isn't mentioned on the wiki page?
If you dig around inside SOTL Altmap, there might be other unmentioned goodies in there too.
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: 2948
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Re: Spurious Planetinfo.plist descriptions?

Post by Wildeblood »

Cholmondely wrote: Wed May 07, 2025 7:09 pm
If you dig around inside SOTL Altmap, there might be other unmentioned goodies in there too.
Ya, ones cim made up. :mrgreen: (I have the impression it's little understood that one can store any arbitrary information one wants to in planetinfo/system.info, as an alternative to mission variables. Perhaps I'll have some suggestions for possibilities later.)

I'm hoping to make a definitive list of properties actually implemented in Oolite as of 1.90/1.91, and correct/update the wiki in the process. Really, if someone could point me to where in the Oolite source planetinfo.plist gets parsed, that would be swell.
R.I.P. John Lodge, 1943-2025.
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2948
Joined: Sat Jun 11, 2011 6:07 am
Location: Nova Hollandia
Contact:

Re: System statistics

Post by Wildeblood »

AND ANOTHER THING!

I've discovered, to my chagrin, that planetinfo.plist has baked the planet's name in to the description in most systems. (!?)
R.I.P. John Lodge, 1943-2025.
User avatar
Cholmondely
Archivist
Archivist
Posts: 6594
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: System statistics

Post by Cholmondely »

Wildeblood wrote: Wed Jun 04, 2025 8:29 am
AND ANOTHER THING!

I've discovered, to my chagrin, that planetinfo.plist has baked the planet's name in to the description in most systems. (!?)
Yes, I found that too. But was using v.0.3 so was going to say nothing until I'd tried v.0.5...
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: 5656
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: System statistics

Post by phkb »

Wildeblood wrote: Wed May 07, 2025 7:37 pm
Really, if someone could point me to where in the Oolite source planetinfo.plist gets parsed, that would be swell.
First quick look led me here: ResourceManager.m, lines 1821-1865
Post Reply