Every now and then I will get Unity stuck in a loop, and have to end task and reload everything. It occurred to me just now that I could use Invoke to exit a potential loop after a few seconds, when debugging a squirrely area of code. Will this tactic protect me, generally, or can I hang it so bad it can't think straight? Is it a bad habit? (Should I be doing something else, such as learning more about try/catch, perhaps? - do they represent all the safety I need?)
↧