Page 1 of 1

Euqipment Activate script

Posted: Sun Mar 24, 2019 10:39 pm
by Maharaja
Is there a way to have equipment trigger a script when its in the power armor of looked on internet but can’t find anything so I ask here now

I want to make a equipment piece that when in a armor it activates a lua script or do I need to do it the other way around when the item is in the armor the script needs to check if it is so it can activate

I’m new to factorio modding I have updated 2 mods but wanted to add something to one of them

Re: Euqipment Activate script

Posted: Mon Mar 25, 2019 8:11 am
by darkfrei
https://lua-api.factorio.com/latest/LuaEquipment.html
I see the only one way: make new prototype "..equipment_disabled", that has no shield. Then by the script swap them, delete one and set the same, but without shield.