When the program has some bugs, like death loop, loop calls, the program will show stack overflow, the unity3d.exe will exit without any infomation.
How to debug this kind of bugs ?
When the program has some bugs, like death loop, loop calls, the program will show stack overflow, the unity3d.exe will exit without any infomation.
How to debug this kind of bugs ?
Infinite loops and recursions are a little tricky to debug because the editor simply stops usually without giving you any information. So, usually the quickest way to find out what's wrong is code review: First, check if there's a specific "situation" which causes the infinite loop/recursion to occur. Usually, that will give you good hints on where to look for the problem.
Then, look at your code and see where there are loops / recursions. If needed, you might want to add some debug-logging. Also, you might comment out some code sections and see if that helps. Or, in Unity, you could also disable full scripts attached to game objects. When the problem disappears after commenting out a code section or disabling an attached script, you know that part likely has to do with the problem.
That way, step by step, you'll get closer until you eventually find it.