Page 1 of 1

Add removed LuaEquipment instance to events

Posted: Sun Feb 19, 2023 9:49 pm
by SWeini
For my mod I'm currently missing a way to recover the fuel's burnt_result when a player removes a burner-powered equipment from an equipment grid. There are on_player_removed_equipment and on_equipment_removed events, but they only contain the prototype of the removed equipment (and count), not the instance(s) containing the relevant burner instance.

And yes, there are mods using burner-powered equipment which is even spitting out fuel containers.

Re: Add removed LuaEquipment instance to events

Posted: Mon May 15, 2023 4:15 pm
by raiguard
The reason that these events don't have LuaEquipment instances is that by the time these events are raised, the equipments no longer exist in the game. So there is nothing to bind the LuaEquipment to.