[TUTORIAL] X Rebirth - Modding Guide
Moderators: Moderators for English X Forum, Scripting / Modding Moderators
-
- Posts: 1411
- Joined: Wed, 15. Nov 06, 10:21
-
- Posts: 190
- Joined: Fri, 30. Jul 10, 05:32
As far as I know, X has always actually preferred to load loose files rather than whatever is in a cat/dat pair:UniTrader wrote:XRebirth still prefers to use files inside Cats/Dats instead of raw files, except you give it a parameter which tells XR to prefer extracted files.
http://forum.egosoft.com/viewtopic.php?p=4100121
Ketraar wrote:technically its the other direction [...] loose files are the last ones to be loaded, thus overwriting everything else
-
- Posts: 45
- Joined: Sun, 30. Jul 06, 13:16
Hello all
After a little help if possible - i cant seem to mod my game. Ive put various mods into the extensions folder, they are all 'on' in extensions ingame, but none of them work.
Question - everytime i put one in the extensions folder, they all have their own 'content.xml' - and im overwriting when copying mods over - do i need to manually edit this file with different info for each mod? What does this file actually do? I presume its what stopping mods from working (no cockpit, Nesa etc)?
Any help much appreciated, thank you in advance.
Tim, captain of the Skunk, signing off.
After a little help if possible - i cant seem to mod my game. Ive put various mods into the extensions folder, they are all 'on' in extensions ingame, but none of them work.
Question - everytime i put one in the extensions folder, they all have their own 'content.xml' - and im overwriting when copying mods over - do i need to manually edit this file with different info for each mod? What does this file actually do? I presume its what stopping mods from working (no cockpit, Nesa etc)?
Any help much appreciated, thank you in advance.
Tim, captain of the Skunk, signing off.
-
- Posts: 1411
- Joined: Wed, 15. Nov 06, 10:21
Just some few hints, first you don't need to change the files altogether, you can simply add or replace part of the entries in the files, that is the power of xml. For the exact syntax read the guide, I'm having problems too for things that are not listed in the guide about the correct syntax. Second you have to add the file upper in the root too, the ones where the items you change are listed, it maybe a matarial (so dds and effects etc) or thers. They generaly are listed in the index folder or in the libraries. Must say that the criteria of listing is quite beyond my coohmprension. Hope for some tool release soon!
-
- Moderator (Script&Mod)
- Posts: 14571
- Joined: Sun, 20. Nov 05, 22:45
every extension needs its own sub-older in bthe extensions-folder so if you do it right it wont overwrite a file in any case.
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
-
- Posts: 13
- Joined: Mon, 29. Sep 08, 14:20
..because i still see outdated and wrong content.xml entries:
i beg you, please read through your content.xml before uploading new or updated mod files.
by the way: the version number has to be multiplied by 100. if you want to see a version "1.20" in the games mod-description, it should look like version="120" in the content.xml.
thanks :)
i beg you, please read through your content.xml before uploading new or updated mod files.
by the way: the version number has to be multiplied by 100. if you want to see a version "1.20" in the games mod-description, it should look like version="120" in the content.xml.
thanks :)
-
- Posts: 1411
- Joined: Wed, 15. Nov 06, 10:21
Trying to use the diff method but not working
ORIGINAL:
If I add instead of at the end of <boost etc.. it works but then disabilitates the following properties (speed and acceleration).
Code: Select all
<diff>
<replace sel="/macros/macro[@name='enginebooster_player_01_macro']/properties/boost">
<boost charge="0" duration="200" minshieldpercent="10" recharge="1">
</replace>
</diff>
Code: Select all
<macros>
<macro name="enginebooster_player_01_macro" class="enginebooster">
<component ref="generic_enginebooster" />
<properties>
<boost charge="0" duration="20" minshieldpercent="10" recharge="1">
<speed forward="10" rotation="0.2" />
<acceleration forward="5" reverse="1" strafe="5" rotation="0.25" />
</boost>
<effects>
<boosting ref="boostfx_engine_player_01" />
</effects>
<sounds>
<charging ref="engine_booster_charge" />
<boosting ref="engine_booster" />
<boosting_lfe ref="engine_booster_lfe" />
</sounds>
</properties>
</macro>
</macros>
Code: Select all
/>
Code: Select all
>
-
- Moderator (Script&Mod)
- Posts: 14571
- Joined: Sun, 20. Nov 05, 22:45
with the <replace> you replace the whole node (everything from <boost ... to ..</boost>, not just the single line given. so you have to re-add the original content, too like this:Realspace wrote:Trying to use the diff method but not working
ORIGINAL:Code: Select all
<diff> <replace sel="/macros/macro[@name='enginebooster_player_01_macro']/properties/boost"> <boost charge="0" duration="200" minshieldpercent="10" recharge="1"> </replace> </diff>
If I addCode: Select all
<macros> <macro name="enginebooster_player_01_macro" class="enginebooster"> <component ref="generic_enginebooster" /> <properties> <boost charge="0" duration="20" minshieldpercent="10" recharge="1"> <speed forward="10" rotation="0.2" /> <acceleration forward="5" reverse="1" strafe="5" rotation="0.25" /> </boost> <effects> <boosting ref="boostfx_engine_player_01" /> </effects> <sounds> <charging ref="engine_booster_charge" /> <boosting ref="engine_booster" /> <boosting_lfe ref="engine_booster_lfe" /> </sounds> </properties> </macro> </macros>
instead ofCode: Select all
/>
at the end of <boost etc.. it works but then disabilitates the following properties (speed and acceleration).Code: Select all
>
iff>
<replace sel="/macros/macro[@name='enginebooster_player_01_macro']/properties/boost">
<boost charge="0" duration="200" minshieldpercent="10" recharge="1">
<speed forward="10" rotation="0.2" />
<acceleration forward="5" reverse="1" strafe="5" rotation="0.25" />
</boost>
</replace>
</diff>
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
-
- Moderator (Script&Mod)
- Posts: 14571
- Joined: Sun, 20. Nov 05, 22:45
hint: use an editor which understands xml - makes everything much easier. (i recommend Notepad++ - has syntax highlight, syntax check, pretty print and autocompletionn with a few settings )
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
-
- Posts: 1411
- Joined: Wed, 15. Nov 06, 10:21
-
- Posts: 13244
- Joined: Fri, 13. Jan 06, 16:39
Added information about the ins and outs of Content.xml.
http://forum.egosoft.com/viewtopic.php? ... 13#4192513
What is relevant to most mods right now:
You can tell the mod to not attach itself to the savegame so it can be uninstalled by turning it off or deleting the whole folder...
without having to "hack" the savegame.
http://forum.egosoft.com/viewtopic.php? ... 13#4192513
What is relevant to most mods right now:
You can tell the mod to not attach itself to the savegame so it can be uninstalled by turning it off or deleting the whole folder...
without having to "hack" the savegame.
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
-
- Moderator (Script&Mod)
- Posts: 14571
- Joined: Sun, 20. Nov 05, 22:45
just added this info to my Mod-Starter-Pack and made a few more improvements:
- improved content.xsd:
-> now knows about the optional save-parameter to be able to remove savegame-safe mods
-> text and depenencies are now optional
- modified scriptproperties.html
-> renamed to default_scriptproperties.html and now depends on the related default_***.xml-Files in the Libraries-folder instead of files with the original Names - prevents conflicts, see next point.
- improved bat-file for removing mod-development related files for creating the package:
-> now removes default_-files mentioned in the previous point instead of the possibly modified original filese (in case you want to modify them)
-> now removes unnecesary folders, if they are empty (except the tools-folder, that one is wiped)
still to find under the same Link:
http://ubuntuone.com/23zTOAse4OkgAjk2ZPIcLL
- improved content.xsd:
-> now knows about the optional save-parameter to be able to remove savegame-safe mods
-> text and depenencies are now optional
- modified scriptproperties.html
-> renamed to default_scriptproperties.html and now depends on the related default_***.xml-Files in the Libraries-folder instead of files with the original Names - prevents conflicts, see next point.
- improved bat-file for removing mod-development related files for creating the package:
-> now removes default_-files mentioned in the previous point instead of the possibly modified original filese (in case you want to modify them)
-> now removes unnecesary folders, if they are empty (except the tools-folder, that one is wiped)
still to find under the same Link:
http://ubuntuone.com/23zTOAse4OkgAjk2ZPIcLL
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
-
- Posts: 5079
- Joined: Fri, 30. Dec 05, 17:47
-
- Posts: 10174
- Joined: Thu, 27. Feb 03, 22:28
Hi Observe,
Firstly thanks for the guide - I have a headache after reading it so it must be good
A question for you if I may. I've been trying to do a Hull Shield mod for capital ship shields for a few days now, but I kept running into issues - basically my understanding is evidently flawed. Dingutis has done something similar to what I indended here but it's not quite what I was hoping to achieve.
I'd started off by first trying to add a new shield type to modify, based on ..assets\props\SurfaceElements\Macros\shieldgenerator_size_m_mk3_macro. My plan was to name it shieldgenerator_m_hull_macro in this test.
To do this I basically copied the contents of said macro, and popped in into an <add sel= so I could modify it's stats independently of the original, buffing its values substantially.
Next, for each ship I wanted to mod in ..assets\units\size_xl\ I'll use a <replace sel to replace the shield generator covering the jumpdrive with my new un-grouped version for it to cover the hull. I am yet to identify this for each ship, but I just need to check the jumpdrive group with the associated shield group to tie the two up.
I thought, in theory, this was a fairly sound approach and, being a NEW shield type, it'd not risk undesired effects on unmodified ships. However, I'm struggling to get things right.
Having seen Dingutis's more straight-forward approach of, basically, ungrouping all shields and giving them a buff, I was inspired to try to get mine working again. I certainly want to first create a proper (working) new shield type for the "hull shield" - actually, several, so I can modify for different ships as need be, and then identify and replace the shield for the jumpdrive as the new hull shield.
I did consider adding an entirely new surface element for the hull shield, but that's way beyond me. Having my modded hull shield on a critical component such as the Jumpdrive works for me. I.e. Take down a ships hull shield, kill it's jumpdrive (no more shield, no insta-escape option) yet you still have a formidable foe to contend with.
Likely I've taken on more than I can handle, as my earlier attempt didn't work, but I'd love to get some advice from you regarding adding this new shield type for use. Once that's in place, I think I have a handle on the remaining bits, so edits to all ships I wish to use the new hull shield variant.
Any advice welcome.
Cheers,
Scoob.
Firstly thanks for the guide - I have a headache after reading it so it must be good
A question for you if I may. I've been trying to do a Hull Shield mod for capital ship shields for a few days now, but I kept running into issues - basically my understanding is evidently flawed. Dingutis has done something similar to what I indended here but it's not quite what I was hoping to achieve.
I'd started off by first trying to add a new shield type to modify, based on ..assets\props\SurfaceElements\Macros\shieldgenerator_size_m_mk3_macro. My plan was to name it shieldgenerator_m_hull_macro in this test.
To do this I basically copied the contents of said macro, and popped in into an <add sel= so I could modify it's stats independently of the original, buffing its values substantially.
Next, for each ship I wanted to mod in ..assets\units\size_xl\ I'll use a <replace sel to replace the shield generator covering the jumpdrive with my new un-grouped version for it to cover the hull. I am yet to identify this for each ship, but I just need to check the jumpdrive group with the associated shield group to tie the two up.
I thought, in theory, this was a fairly sound approach and, being a NEW shield type, it'd not risk undesired effects on unmodified ships. However, I'm struggling to get things right.
Having seen Dingutis's more straight-forward approach of, basically, ungrouping all shields and giving them a buff, I was inspired to try to get mine working again. I certainly want to first create a proper (working) new shield type for the "hull shield" - actually, several, so I can modify for different ships as need be, and then identify and replace the shield for the jumpdrive as the new hull shield.
I did consider adding an entirely new surface element for the hull shield, but that's way beyond me. Having my modded hull shield on a critical component such as the Jumpdrive works for me. I.e. Take down a ships hull shield, kill it's jumpdrive (no more shield, no insta-escape option) yet you still have a formidable foe to contend with.
Likely I've taken on more than I can handle, as my earlier attempt didn't work, but I'd love to get some advice from you regarding adding this new shield type for use. Once that's in place, I think I have a handle on the remaining bits, so edits to all ships I wish to use the new hull shield variant.
Any advice welcome.
Cheers,
Scoob.
-
- Moderator (Script&Mod)
- Posts: 14571
- Joined: Sun, 20. Nov 05, 22:45
one more info about content.xml:
<content>-node has an enabled-Parameter which when set to "false" turns mods off by default. Updated content.xsd in myStarter pack. (will make a Topic about it when i decided which cat-tool to include)
[Post about Content.xml updated. - Gazz]
<content>-node has an enabled-Parameter which when set to "false" turns mods off by default. Updated content.xsd in myStarter pack. (will make a Topic about it when i decided which cat-tool to include)
[Post about Content.xml updated. - Gazz]
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
-
- Posts: 15
- Joined: Sun, 14. Oct 07, 16:04
-
- Moderator (Script&Mod)
- Posts: 14571
- Joined: Sun, 20. Nov 05, 22:45
what kind of data do you want to store where?
if not stated otherwise everything i post is licensed under WTFPL
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
Ich mache keine S&M-Auftragsarbeiten, aber wenn es fragen gibt wie man etwas umsetzen kann helfe ich gerne weiter
I wont do Script&Mod Request work, but if there are questions how to do something i will GLaDly help
-
- Posts: 15
- Joined: Sun, 14. Oct 07, 16:04