1083 Modding Bug / Datafile Bug

Moderator: MOD_DW2

Post Reply
mordachai
Posts: 800
Joined: Fri Mar 06, 2015 4:55 pm

1083 Modding Bug / Datafile Bug

Post by mordachai »

I have edited every ShipHulls*.xml (the base + all races) - so that Interceptors which have two weapons always use small weapons. Always. MaxComponentSize 5.

And yet... this game refuses to honor that, yet again.

I thought I had it working - then you guys added the ShipHulls_<Race>.xml files. So I added those to my mod and fixed them all.

And now, yet again in 1083, I'm staring at an Ackdarian auto created interceptor - size 20, maximumsize 77 (which seems to be level 4) - and YET AGAIN the game designed it with a single large weapon and ignored the small slot.

SO MUCH WRONG WITH THAT.

1. It should put weapons in all slots, energy permitting
2. it should only have small slots per the xml files

Happy to share my screen - walk through every blasted file with someone from your team, showing that every !~@#$!@## copy of that fighterinterceptor hull is 5 + 5 max weapon size, and yet the game designs it with 5/10 (and leaves the 5 empty).

What gives? What other possible file is it looking at?

I did NOT update the pirate files. I assume (?!@#) that those are not relevant for any of the races who have a shiphulls_race.xml file?
Sabranan
Posts: 486
Joined: Wed Feb 24, 2016 4:05 pm

Re: 1083 Modding Bug / Datafile Bug

Post by Sabranan »

Any edits to the default ShipHulls.xml file will effectively be ignored, as the ShipHulls*.xml will override any entries with matching IDs. Additions to the base file will still be applied though.

If you're starting from a base installation, you can actually safely delete the ShipHulls.xml file, we've only left it in place so as not to screw up existing modder's work.

If you've made changes to any of the shiphull files, you'll need to delete the appropriate entries under \data\ShipHullModelData\Ships\Racename to force the game to regenerate the models.

You can also just delete the entire ShipHullModelData folder, but that will make the first game you start afterwards take rather longer to generate the galaxy!
mordachai
Posts: 800
Joined: Fri Mar 06, 2015 4:55 pm

Re: 1083 Modding Bug / Datafile Bug

Post by mordachai »

Sabranan wrote: Mon Oct 31, 2022 11:01 pm Any edits to the default ShipHulls.xml file will effectively be ignored, as the ShipHulls*.xml will override any entries with matching IDs. Additions to the base file will still be applied though.
This part I get - but it sounds like...
Sabranan wrote: Mon Oct 31, 2022 11:01 pm If you've made changes to any of the shiphull files, you'll need to delete the appropriate entries under \data\ShipHullModelData\Ships\Racename to force the game to regenerate the models.

You can also just delete the entire ShipHullModelData folder, but that will make the first game you start afterwards take rather longer to generate the galaxy!
that this part means that the game generates .shmd files from the xml -

and I'm assuming that those are pre-generated?
and hence any changes I were to make to ShipHulls_Ackdarian.xml (for example) won't be picked up no matter what - unless I delete the associated .shmd files and force the game engine to regenerate those the next time I start a game, which it will do automatically?

And the architecture now means:
  • modders can add xml content, and it will autogenerate the shmd _but only the first time_
  • BUT, modders cannot alter base game content - not without instructing their players to delete those files manually themselves?
So even new content really requires that the modder supply the latest .shmd files along with the .xml in order to ensure they're up to date, no?
Post Reply

Return to “Distant Worlds 2: Tech Support”