fixes the root cause of many crashes that point to same line.
TL;DR
error() throws an exception basically and causes everything to crash. Logging the error, especially if it's not critical, seems the more sensible thing to do.
Long explanation:
at least 3 different errors all boil down to same line job_corutine.lua:42
fixes #20 amongst other things.
A lot of other mods and even the default game assume that actions are performed by the player only and do not expect villagers to be interacting with certain nodes and entities. It is virtually impossible to debug each and every one of them or add extra code in this mod to account for it. For example #39 adds further logic to remember failed nodes but if every node fails, we run the risk of out of memory issues as the list of failed nodes grows and grows.
While it seems tempting to throw an error to force the user to report the issue, it just makes the average user think that this mod is broken and they will more likely just uninstall it.
fixes the root cause of many crashes that point to same line.
TL;DR
error()
throws an exception basically and causes everything to crash. Logging the error, especially if it's not critical, seems the more sensible thing to do.Long explanation:
at least 3 different errors all boil down to same line job_corutine.lua:42
fixes #20 amongst other things.
A lot of other mods and even the default game assume that actions are performed by the player only and do not expect villagers to be interacting with certain nodes and entities. It is virtually impossible to debug each and every one of them or add extra code in this mod to account for it. For example #39 adds further logic to remember failed nodes but if every node fails, we run the risk of out of memory issues as the list of failed nodes grows and grows.
While it seems tempting to throw an error to force the user to report the issue, it just makes the average user think that this mod is broken and they will more likely just uninstall it.