- Home /
Problems playing animation when time hits zero.
Fixed it my self.
Have you first properly debugged endTime and timeLeft to see what their values are?
Ofcourse not, because he wants us to do his work. What's happening now is they copy paste a code that appears to be close to what they want and they ask people to continue the work.
You are having issues, but you don't explain what your issues are ...
Does your timer reach 0 ? The animation is not playing ? The code is not compiling ?
What is happening ? Or what should happen and is not ?
Answer by bubzy · Jun 12, 2013 at 09:47 AM
agree. if you cannot code a countdown and an event when its complete, you need to read up some more coding resources, not ask here.
countdown =10
if countTimeUp then
countdown --
if countdown = 0
event
The more standard "simple" countdown in Unity is to set the event time to gameTime seconds, then check Time.time
each update.