Simple Mod to add a faction to existing wares

The place to discuss scripting and game modifications for X4: Foundations.

Moderators: Scripting / Modding Moderators, Moderators for English X Forum

ArgonExplorer3579
Posts: 12
Joined: Sun, 31. May 20, 22:56
x4

Simple Mod to add a faction to existing wares

Post by ArgonExplorer3579 »

I tired to add the paranid faction to the ares fighter with no luck. Any help will be gladly apprectiated
<add sel="/wares">
<ware id="ship_par_s_heavyfighter_01_a" />
<owner faction="paranid" />
</ware>
</add>
User avatar
Shuulo
Posts: 1633
Joined: Mon, 14. Apr 08, 17:03
x4

Re: Simple Mod to add a faction to existing wares

Post by Shuulo »

You are doing it wrong

Code: Select all

 
 <add sel="//wares/ware[@id='ship_par_s_heavyfighter_01_a']">
  <owner faction="paranid" />
 </add>
  
By using your method you add new ware with the same name as existing one to the wares list (you also close it immediately with "/"), then owner thing directly to wares list, not to a specific ware. Thats why its not working
You need to add owner to a specific ware and it has to be in sel= thing.

Return to “X4: Foundations - Scripts and Modding”