Nuclear Scorch Decay


Continuously removes nuclear scorch marks by slowly changing the scorched tiles to match their surroundings.

Tweaks
6 months ago
2.0
442
Environment

b Crash after removing planet mod

4 months ago

After removing a planet mod the game will crash on load with the following exception:

The mod Nuclear Scorch Decay (0.1.0) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event nuclear-scorch-decay::on_nth_tick(10)
LuaSurface API call when LuaSurface was invalid.
stack traceback:
        [C]: in function '__index'
        __nuclear-scorch-decay__/control.lua:111: in function <__nuclear-scorch-decay__/control.lua:99>
4 months ago

Thanks for the error report, I'm not actively developing this mod but I think I can guess where the error is and I'll push a fix in the next few days.

In the meantime, as a workaround you should be able to reset the mod's surface list and resume your save by removing the mod entirely, saving the world without the mod installed, and then reinstalling it. The order of operations should be:

  • Copy the world / make a backup save, just in case
  • Remove Nuclear Scorch Decay
  • Load the save, then immediately save and quit
  • Reinstall Nuclear Scorch Decay
  • Load, save again, continue playing

As long as the save doesn't include the mod it won't have the mod's storage table, which contains the data on the world's surfaces and whatnot, which means the mod will create a fresh one without the removed surface on reinstall.

Let me know if this doesn't work, that means the error is a lot more complex and I'll need to set an afternoon aside for it.

3 months ago

Actually that worked, I just removed, saved, added and loaded and this mod is working alright once again.

3 months ago
(updated 3 months ago)

I can't actually see how the error you encountered could have happened. The game provides an "on_configuration_changed" event that allows you to call a function whenever a mod is added, removed or updated; and in this mod's function for that event the mod deletes its stored list of surfaces and makes a new one. I have no idea how it could have skipped that and tried to modify a surface that had been removed, as removing it should have caused it to refresh everything.

As long as the workaround works it's not the end of the world, but I'm going to have to look deeper into this. If you still have a copy of the world folder as it was when it was broken it would help me out a lot if I could take a look at it. Thanks either way.

New response