How to sell a custom factory factories in shipyard? [SOLVED]

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

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

Post Reply
StevieLeeCole
Posts: 40
Joined: Fri, 10. Jul 15, 18:31
x4

How to sell a custom factory factories in shipyard? [SOLVED]

Post by StevieLeeCole » Tue, 17. Aug 21, 14:10

I've created two custom factories, that produce custom weapons. The weapons and factories appear and work fine in game, but when I try to place the factories into the OTAS shipyard (in WareTemplate) for sale, they will not appear on the list for sale in game. I've placed other factories and the complex construction kit there, so the problem seems to be my custom factories. They are copies of the IRE factory, except they each produce two weapons, but using same building materials and secondary. The two product thing is the only odd thing about them, and I am baffled, because it seems like it should work. I've double and triple checked (even re-pasted) the text in case of unintended format errors or something into WareTemplate within the OTAS shipyard, but it all looks perfect. Checked the entries in TFactories and WareTemplate for them as well and they look fine (they should because they work fine as factories in game-- can dock and buy custom weapons and install in ship). The fact that vanilla factories before and after my custom ones work indicate the problem is NOT a format error. Ideas?
I've added evidence to my hypothesis that it could be the double product that is causing problems. I made a custom Beluga missile factory which appears fine both as a station and for sale in the shipyard. Finally confirmed hypothesis; removed one product from each station; the stations then appear in the shipyard menu for sale.

TL;DR-- If you want to sell a custom factory in the shipyard, it CANNOT have more than one product. My solution is to keep the multiple-product (OTAS Light and Medium Weapons factories) as stand-alones and create new factories that only produce a single weapon as the "for sale" version at shipyards.

Post Reply

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”