What event is fired when tile deconstruction is cancelled?
Posted: Sat Aug 26, 2023 10:13 am
Hello! I am having trouble with detecting cancellation of tiles deconstruction.
I have tried to add handler for on_cancelled_deconstruction event but it fires only for regular entities/buildings. It does not work for deconstructible-tile-proxy.
Does anyone have ideas about how to work around this issue?
My code snippet:
I have tried to add handler for on_cancelled_deconstruction event but it fires only for regular entities/buildings. It does not work for deconstructible-tile-proxy.
Does anyone have ideas about how to work around this issue?
My code snippet:
Code: Select all
script.on_event(defines.events.on_cancelled_deconstruction,
function(event)
if event.entity.name == "deconstructible-tile-proxy" then
--- does not reach here
else
--- works for regular entities
end
end
)