raiguard / Krastorio2

An overhaul mod for Factorio focusing on end-game technologies and moderately increased complexity.
https://mods.factorio.com/mod/Krastorio2
GNU Lesser General Public License v3.0
119 stars 49 forks source link

Tesla Coil behaves very randomly when trying to charge the armor #355

Closed Duck986 closed 1 year ago

Duck986 commented 1 year ago

Description

Most of the time Tesla Coil doesn't charge the armor if it has an absorber inside, yet the armor has exoskeletons, shields, etc. image image You can see that no electric trail follows from the coil to the character. It happens randomly when equipping and unequipping the armor.

Bonus: The coil also doesn't charge if you change the armors within its radius - you will have to move outside and back inside for it to charge the new armor.

Reproduction

1) Load the file: [item=ee-super-lab] EDITOR.zip 2) See no charge 3) Cry 4) Repeat on scenario or on regular save to cry even more

raiguard commented 1 year ago

This is happening due to the other power armor in your inventory, which contains an energy absorber. I failed to add logic to detect when the player changes armors.