If you deconstruct a refueler combinator with bots, the station that it was attached to gets put in a state where it crashes the game if you try to build another cybersyn combinator for it, or deconstruct the station.
I fixed it locally by adding a simple if (network)
check in main.lua:88
, but the real issue is probably the fact that the network data doesn't get cleared when the combinator is deconstructed.
The crash looks like this:
Error while running event cybersyn::on_pre_player_mined_item (ID 11)
__cybersyn__/scripts/main.lua:88: attempt to index local 'network' (a nil value)
stack traceback:
__cybersyn__/scripts/main.lua:88: in function 'on_refueler_broken'
__cybersyn__/scripts/main.lua:519: in function 'on_stop_broken'
__cybersyn__/scripts/main.lua:601: in function <__cybersyn__/scripts/main.lua:596>