Is there a way to prevent a script from being disabled on exception. I am trying to make my save game script so it resets the save game file if any of the saved values become invalid when it throws the exception “OutOfMemoryException: Out of memory” But the script disables itself so It doesn’t delete and rewrite the corrupted save file. Anyone know a way to re-enable or keep the script enabled when an exception occurs or to find a way around this?
You should validate values yourself, not wait for an exception. And if your validation fails, then you can do your thing with no exceptions involved
The lazy way would be to just put everything in a try-catch block, but that’s the worse out of this two ideas