Join us at the Oolite Anniversary Party -- London, 7th July 2024, 1pm
More details in this thread.

Planetfall OXP

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

Moderators: winston, another_commander

User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

pagroove wrote:
Well I'ts not very realistic but it would give some meaning to locations 'in the field'. For now the planetary option and the repairs are a bit expensive in comparison with the benefits from it. But I agree. There are some good mission writers out here who could generate some great missions.
The "in the field" locations were designed to be "useless". They don't appear that often (it's only 2% chance iirc for the built-in ones) and are just there to provide a little variety. It's to keep the realism, that it's not always going to be possible to trade or equip everywhere you land.

The whole idea of planetfall was to make the planets something a little more than just something to remember not to crash into. All of the built-in locations have their own commodities.plist, so you can get (sometimes) better deals on stuff there than at the main station, and equally some locations have better tech level than their systems.

Plus as you say it's written to be expandable, so OXP mission writers can use it as a base location for offering or staging missions.

Eric Walch wrote:
The JS command runMissionScreen does try to clear the image immediately after showing. Maybe it does not clear memory when an image is at display.
Anyhow, in the past it was always necessary to clean the screen first before showing a mission screen. runMissionScreen does that by itself by passing a null picture when none is defined. In legacy the script must always do that itself.
Thanks for the info. I put a little catch-code into the taxi mission to ensure that if the scripted launch/mission background image bug is triggered then the script resets the background to null. I might add that code into the main script too at the next revision. But at the moment it's called via the runMissionScreen command, so should work as you describe anyway.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Small update to the script, now at version 1.1.2. Two reasons:

  • Bugfix to stop the planet scanning in interstellar space. With thanks to Eric for the catch.
  • Little addition to the code, with a new variable worldScripts.PlanetFall.planetFallOverride, which if set to true will only allow external OXP locations, removing all the others.
The new variable is designed so that PlanetFall can be an effective host for locations for other OXPs and missions without the default locations getting in the way. Just don't forget to reset it to false once you're done with it please OXP and mission writers!

Download full v1.1.2 of Planetfall.

Alternatively for those with 1.1x, you can just patch it with this script file (use it to replace the existing one in the config folder of the 1.1x OXP).

Oh and the link in the wiki will of course now not work for downloading, as it's read-only at the moment and I can't change it.[/color]
Last edited by Thargoid on Sun Feb 08, 2009 3:07 pm, edited 1 time in total.
User avatar
pagroove
---- E L I T E ----
---- E L I T E ----
Posts: 3035
Joined: Wed Feb 21, 2007 11:52 pm
Location: On a famous planet

Post by pagroove »

Thats a nice add on in the code Thargoid!

I did not progress on making more locations a.t.m. but I will. I did however made a nice Zadies texture for the next FP pack. Locations pack will be seperate.
For P.A. Groove's music check
https://soundcloud.com/p-a-groove
Famous Planets v 2.7. (for Povray)
Image
https://bb.oolite.space/viewtopic.php?f=4&t=13709
User avatar
Divas Kind Imps
Average
Average
Posts: 15
Joined: Tue Dec 09, 2008 4:09 am
Location: Seattle

A taxi mission that cannot be run?

Post by Divas Kind Imps »

Hi Thargoid,

Planetfall is great! I'm running Oolite 1.72.2 and the latest Planetfall oxp. As I understand the oxp, the Taxi mission allows for a local taxi-ride to a local body based on what is in a given planetary system. I am not running the System Redux oxp, however I've docked at the station orbiting Learorce in Galaxy One. I accepted a Taxi fare to travel to Learorce Minor. There is no Learorce Minor- or could the script be interpreting another oxp's station as the Minor locale?

Bug?
Dunno.

Can't really take the fare anywhere, or am I just daft - yeah, likely the latter, but... .

Will provide list of oxps if needed.
As for the user name...

It is what happens when Thargoids become identity thieves and having ravaged an account to fund their war-efforts, leave your empty coffers and account profiles with re-engineered and totally Thargodized (a new verb?) name.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

It should only offer trips to "Minor" and "Moon of" locations if they exist in the system as you say (it scans for planets, so OXP stations aren't included). So either you have something else that's adding those (system redux isn't the only one that does), or there is a glitch yes.

But if you want to ditch the mission just go to another system and dock somewhere. Your rather indignant passenger will get off the ship.

Anyway I'll have a look over the taxi mission script as it may be that it needs a little refining somewhere.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

OK, I think I've found the problem. In the taxi script is a line:

Code: Select all

if(worldScripts.PlanetFall.planetCount == 0 || worldScripts.PlanetFall.lastPlanetType == "Sub")
The planetCount == 0 is wrong, it should be == 1 (as there is always the main planet in the system, so the count should never be zero).

Anyway, you can either change the 0 to 1 in your script, or alternatively download the updated version (PlanetFall Taxi v1.0.1) from my webspace.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

As detailed here, I'm pleased to add the Planetfall Oo-Haul Mission add-on to the OXP.

It offers a similar escort mission to that in Oo-Haul, but going the other way - from planet to witchpoint (or constore with YAH installed). Full details are in the Oo-Haul thread linked above, to save me writing everything twice :)
User avatar
pagroove
---- E L I T E ----
---- E L I T E ----
Posts: 3035
Joined: Wed Feb 21, 2007 11:52 pm
Location: On a famous planet

Post by pagroove »

Nice to see you still supporting this OXP. I will try to make some additional locations once Famous Planets is done. :D
For P.A. Groove's music check
https://soundcloud.com/p-a-groove
Famous Planets v 2.7. (for Povray)
Image
https://bb.oolite.space/viewtopic.php?f=4&t=13709
overmage
Deadly
Deadly
Posts: 128
Joined: Mon Mar 23, 2009 6:55 pm

Post by overmage »

The link on the wiki is broken and links to the older version. I wanted to edit it, but got this error message: You need to be logged in to edit pages.

So I tried to create an account and:

You are not allowed to create an account
To be allowed to create accounts in this Wiki you have to log in and have the appropriate permissions.
Return to Main Page.

:(
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

The wiki is read only at the moment, as it's having hardware problems with its server (there's a thread about it here). Hence I can't update the link there to point to the correct place. Or to be fully exact the hardware problems were briefly fixed and I did update it, but then they recurred and Winston had to put everything back on his own back-up server under read-only again and with the old version).

The current location of all my OXPs is on box.net, via the link in my sig below. Once the wiki gets sorted out (again) I'll update my links page accordingly (again). But thanks for the consideration to post it anyway.
User avatar
Ark
---- E L I T E ----
---- E L I T E ----
Posts: 664
Joined: Sun Dec 09, 2007 8:22 am
Location: Athens Greece

Post by Ark »

Great job Thargoid.
Sorry about my absence :oops: . It seems that this RL disease is contagious and since lately I was in a very close proximity with Doc Nil …….
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

This OXP is now also updated to V1.2, compatible with Oolite V1.73.

Download is available via the first post in this thread, or from the links below.
Chaky
Deadly
Deadly
Posts: 213
Joined: Sat Aug 15, 2009 6:15 am

Post by Chaky »

I think I've discovered a nasty typo in script.js. You forgot to put {} in line 126 and 251.

Same goes for v1.12 and v1.2
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

Chaky wrote:
I think I've discovered a nasty typo in script.js. You forgot to put {} in line 126 and 251.
No, it is correct. Without {} after the else only one statement after else is executed. In this case the if statement in line 127. But that single if statement itself runs until line 251.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5525
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Thanks for pointing it out though. As Eric says it does actually work as it is, although in terms of programming style it's inconsistent so not a good code example.

That said the script there is basically a multi-nested set of if...then...else statements anyway, so isn't the nicest example to read through.

I'll add the brackets in next time I need to update things, but in itself I don't think is a necessary update on its own.
Post Reply