graftorio2 icon indicating copy to clipboard operation
graftorio2 copied to clipboard

Power poles do not restore copper connections after being destroyed

Open anpavlov opened this issue 2 years ago • 1 comments

When power pole get destroyed by biter or weapon and ghost entity is created, the ghost entity does not show previously existing connections of copper cable and thus not restoring them when pole is built again

https://user-images.githubusercontent.com/10996983/197990503-37141f43-d1fb-4c65-af4b-168f972063fc.mp4

anpavlov avatar Oct 26 '22 09:10 anpavlov

By deactivating mods one by one, found it is a graftorio2 issue

anpavlov avatar Oct 26 '22 09:10 anpavlov

https://github.com/remijouannet/graftorio2/blob/fb0b352fd8a215db335fa1a1e99454f5ee6c40fc/power.lua#L113-L116

marimelon avatar Nov 18 '22 05:11 marimelon

i think the bug is on_power_destroy should not treat the entity the same way if it was "kill" or "destroy", i need to find something in the Lua API that tells me if the entity was kill or destroy

remijouannet avatar Nov 18 '22 17:11 remijouannet

should be fix in 0.0.18

Capture d’écran 2022-11-18 à 19 03 09

remijouannet avatar Nov 18 '22 18:11 remijouannet