i’m trying to have quick afterburner where when a Key is pressed, the movementforward speed changes to say 3000 for 1 second then back to normal speed, giving arcadey afterburner effect… but i’m not sure how to do this? i’ve tried waitForSeconds or starting a coroutine but both give errors… any suggestions ?
What i need sounds really simple, when Space is pressed, CurrentSpeed = BurstSpeed for 2 seconds, then CurrentSpeed is back to being movementForwardSpeed
I’m sorry, that is correct; you should only allow it to activate once until it’s done. I was trying to answer why the coroutine didn’t start, and didn’t “complete” the rest of the code for the situation.
You could also use a bool to indicate you’re using the afterburner.
yeah, for some reason none of the methods here work, the boost only stays for about half a second then goes, so i think i’ll change the system to meter system where if the meter at 0% then boost is not available and recovers automatically when boost is not used.