- Home /
When i press the key to run the animation it pauses my game! HELP!
Hello everyone i need help with a problem i made a walking animation so when i am going to press a certain key like W on the keyboard. But when i press the key my game pauses itself. i dont get into scene again i am paused but the game is running somehow. Here is the script.
function Update() { if(Input.GetKeyDown("w")) { // Plays the walkanimation animation - stops all other animations animation.Play("walkanimation", PlayMode.StopAll); } }
How to fix? I am making a fps game!. Please help! And its like the script is making it.Cuz the animation is running automatically in game with no script.But when i insert the script it runs the same but when i want to press the key that makes me go forward the games pauses but its still running somehow! Please help! And please add me on Skype Niklas7715 Thanks!
Pauses your whole game, or the walk animation just stops? And do you want the animation to play automatically at start? If you could post some code it may help. :)
Sounds like a misused while loop to me. Post some code for real answers.
Its like when i press on play it starts the game and the animation is going automatically.and when i am pressing the key w on my keyboard it pauses my game! Please help me.
$$anonymous$$aybe somewhere in your code you have Time.timeScale = 0.0; if W is pressed? xD posting some code might help you dude!
Where do you think i could place the time.timescale = 0.0?