reload OXPs during development

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

Moderators: winston, another_commander

Post Reply
User avatar
MCO
Poor
Poor
Posts: 7
Joined: Fri Jan 20, 2017 11:23 pm

reload OXPs during development

Post by MCO »

it's me - again.
after messing around with some OXPs code and thinking about making one myself, i realized that i have to perform the following steps every time i test my code: go to main menu - manage expansion packs - install or remove a dummy pack - return to menu - load my commander - launch. especially the (de)installation is incredibly annoying, because i tend to work offline and therefor need to cheer up my connection to actually connect every second time.
now, is there any simpler way to do this? possibly from the main menu, or even within the game? how do oxp coders not fall to madness like this? :(
or maybe a good soul is willing to implement such a button with an oxp?
any help is appreciated!
Honorable Trader/Pirate Hunter.
Current Kill Count: 544
User avatar
Cody
Sharp Shooter Spam Assassin
Sharp Shooter Spam Assassin
Posts: 16081
Joined: Sat Jul 04, 2009 9:31 pm
Location: The Lizard's Claw
Contact:

Re: reload OXPs during development

Post by Cody »

Work from an OXP/OXZ in your AddOns folder - no need for online stuff. Or have I misunderstood?
You can add or remove OXZs manually from your ManagedAddOns folder too.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6682
Joined: Wed Feb 28, 2007 7:54 am

Re: reload OXPs during development

Post by another_commander »

Press the Shift key while starting the game and hold it till the rotating Cobra appears; this will flush the game cache and reload all OXPs from scratch, including any changes you have made.

If you find this too cumbersome, add the always-flush-cache key to your .GNUstepDefaults and set it to YES. Pasting from the wiki:
Key: always-flush-cache
Type: boolean
Default: NO
Introduced: 1.73
If set to YES, the data cache will be rebuilt each time Oolite runs. This is roughly equivalent to placing a brick on your shift key.
User avatar
Stormrider
Deadly
Deadly
Posts: 241
Joined: Sat Jan 25, 2014 2:35 am
Location: At work

Re: reload OXPs during development

Post by Stormrider »

I like to use cim's build scripts, they require a little set up but once they are they will repackage an oxp as an oxz and replace the old oxz in your AddOns folder with the new one. They work out of the box on linux but require some modification to work on Windows or Mac.
https://github.com/cim--/oxp-build-scripts
Image
Post Reply