Quantcast
Channel: Questions in topic: "error message"
Viewing all articles
Browse latest Browse all 2891

Unity Crashes When Clicking Play: Script Error?

$
0
0
I have an issue, whenever I try to click play in the Unity Editor, the Editor freezes. This might be caused by a script error. According to this post http://answers.unity3d.com/questions/756762/unity-bug-not-responding-when-i-try-to-play.html My Do/While script has a loop. Is there a way to fix it? I am running Windows 10 x64 with Unity 5.3.5 (latest) version. Here is the code that may have been causing the problem: using UnityEngine; public static class Helper { public static float ClampAngle(float angle, float min, float max) { do { if (angle < -360) angle += 360; if (angle > -360) angle -= 360; } while (angle < -360 || angle > 360); return Mathf.Clamp (angle, min, max); } }

Viewing all articles
Browse latest Browse all 2891

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>