- Home /
Question by
Killer321 · Sep 16, 2012 at 03:27 PM ·
waitforsecondstimescalekey
Press Key for higher TimeScale and WaitForSeconds for lower TimeScale
Hey im new in things like Scripting and i need Help.Ahm i think this is false i want to press left ctrl then should my player run and if i wait 8 secs he should be again normaly walking.
Heres my Noob Script :D
function Update () {
if (Input.GetKeyDown("left ctrl")) {
Time.timeScale = 3.0; } if (Time.timeScale = 3.0) {
yield WaitForSeconds (8);
Time.timeScale = 1.0; } }
Hope you can help
Greetings
Comment
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Use Button 1 Answer
how to apply "WaitForSeconds" ? Help Me 1 Answer
play animation when press key 2 Answers
C# yield waitforseconds 3 Answers