Quantcast
Channel: Questions in topic: "crash"
Viewing all articles
Browse latest Browse all 2383

Why does unity keep crashing when I use this script

$
0
0
Whenever I press Left Shift in play mode which is my running cue, Unity freezes and I need to use task manager to close it. Does anyone know what to do if this happens. Here is my script #pragma strict var Hands : Transform; var PlayAnimation : boolean = false; function Update() { while(Input.GetKeyDown(KeyCode.LeftShift)) { PlayAnimation = true; if(PlayAnimation == true) { Hands.animation.Play("GlockRun"); } } if(Input.GetKeyUp(KeyCode.LeftShift)) { PlayAnimation = false; } }

Viewing all articles
Browse latest Browse all 2383

Trending Articles



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