Page 1 of 1

Enable removal or hiding of shield equipment and active defense equipment

Posted: Thu Feb 29, 2024 11:58 am
by derpumu
For the Pacifist mod I tried to remove all active defense equipment and energy shield equipment but could not. Upon start, the game displays an error that basically tells me it can't deal with no existing prototypes of these types.

The obvious solution that worked with all other kinds of "must have" prototypes (guns, artillery wagon, turrets in all flavors...) was to add dummy prototypes with the flag "hidden" - but EquipmentPrototype and the derived types do not support these flags.

While practically those dummies equipments can never be built because no item exists with the right placed_as_equipment_result, they still show up e.g. in the RecipeBook mod.

The preferred solution would be to just allow 0 instances of all these prototypes (see https://github.com/Derpumu/Pacifist/blo ... ummies.lua for a list of all the ones I found). I can imagine that that may be some work on the API and the engine, so adding a flags attribute to EquipmentPrototype should do the trick as well.

Re: Enable removal or hiding of shield equipment and active defense equipment

Posted: Thu Feb 29, 2024 1:49 pm
by Nidan
Are you aware of the no base mod? It should help you figuring out the minimal properties you need.

Re: Enable removal or hiding of shield equipment and active defense equipment

Posted: Thu Feb 29, 2024 5:51 pm
by derpumu
I wasn't aware, so thanks for the link. However, minimal properties are not the issue here. The inability to truly hide the mentioned equipments is the problem