So when I make an OXP I would recreate the directory structure of Contents\ but do it under the Addons\ dir?
So under Addons\ I would have:
Contents\
*Resources\
**AIs
**Config
**Images
**Models
**Music
**Sounds
**Textures
Now if I change shipdata.plist I would place it under Addons\Contents\Resources\Config, right? And that would override the default shipdata.plist.
How do I know if my OXP was loaded from the Addons dir? Is there a way to print a message to the screen when Oolite starts up? Or is a log file the only way to know this?
I just want to start with something simple, like change the max speed of my cobra MK 3.
Thanks.
Newbie: Addons dir structure question
Moderators: winston, another_commander
- LittleBear
- ---- E L I T E ----
- Posts: 2882
- Joined: Tue Apr 04, 2006 7:02 pm
- Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.
For an OXP it needs to be in a folder called nameofoxp.oxp (the .oxp must be lower case). Inside this you put folders called Config, Models etc.
So to mod the Cobra Mk III, copy the shipdata and shipyard .plists to the Config folder of your OXP folder in AddOns. Then fiddle with the entries for the CobraIII. The shipyard.plist controls the player version of the ship in terms of price etc. The shipdata.plist controls its stats. You need to change the entry that ends -player though (otherwise only NPC versions would be affected.)
When you load up Oolite hold down the SHIFT key to refresh the cache (otherwise the changes you made are not updated). The stddr file logs the OXPs that have been loaded and reports errors (if any) in them.
So to mod the Cobra Mk III, copy the shipdata and shipyard .plists to the Config folder of your OXP folder in AddOns. Then fiddle with the entries for the CobraIII. The shipyard.plist controls the player version of the ship in terms of price etc. The shipdata.plist controls its stats. You need to change the entry that ends -player though (otherwise only NPC versions would be affected.)
When you load up Oolite hold down the SHIFT key to refresh the cache (otherwise the changes you made are not updated). The stddr file logs the OXPs that have been loaded and reports errors (if any) in them.
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
- LittleBear
- ---- E L I T E ----
- Posts: 2882
- Joined: Tue Apr 04, 2006 7:02 pm
- Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.
Yep.
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
- Commander McLane
- ---- E L I T E ----
- Posts: 9520
- Joined: Thu Dec 14, 2006 9:08 am
- Location: a Hacker Outpost in a moderately remote area
- Contact:
My advice: Just open any of the OXPs you have (if you don't have any, download some), and look what's inside.
To open an OXP you right-click on it and choose "Open Package" or something reasonably similar from the pop-up menu. Then it opens just like an ordinary folder (it is just an ordinary folder, except it is treated as a package, because of its ".oxp" extension).
This is so much easier than complicated explanations here on the board.
And for your second step you can open the plists in the AIs and Config folder of your sample OXP and study them. (If you're on a Mac, I'd recommend a plist-editor for that, but it's not necessary. A simple text editor will do.)
To open an OXP you right-click on it and choose "Open Package" or something reasonably similar from the pop-up menu. Then it opens just like an ordinary folder (it is just an ordinary folder, except it is treated as a package, because of its ".oxp" extension).
This is so much easier than complicated explanations here on the board.
And for your second step you can open the plists in the AIs and Config folder of your sample OXP and study them. (If you're on a Mac, I'd recommend a plist-editor for that, but it's not necessary. A simple text editor will do.)
- Star Gazer
- ---- E L I T E ----
- Posts: 633
- Joined: Sat Aug 14, 2004 4:55 pm
- Location: North Norfolk, UK, (Average Agricultural, Feudal States,Tech Level 8)
There's loads of suitable stuff available, many for free. You could try MetaPad, NotePad++, or jEdit. They are all text editors with the ability to output all the necessary characters for plists.
In the days when I was forced to use Windows PCs, I often used MetaPad for all sorts of purposes, including writing HTML documents and small batch files.
In the days when I was forced to use Windows PCs, I often used MetaPad for all sorts of purposes, including writing HTML documents and small batch files.
Very funny, Scotty, now beam down my clothes...
- LittleBear
- ---- E L I T E ----
- Posts: 2882
- Joined: Tue Apr 04, 2006 7:02 pm
- Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.
Bog Standard Notepad does the trick. The only thing is as .plist is a Mac format its best to copy in an existing .plist. Then delete all the text after opening with Notepad and save. You then have a blank file in .plist format.
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
- Commander McLane
- ---- E L I T E ----
- Posts: 9520
- Joined: Thu Dec 14, 2006 9:08 am
- Location: a Hacker Outpost in a moderately remote area
- Contact: