Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Count down help?

Asked by 9 years ago

I'm trying to make a countdown script, but when I start it up, but it counts down from 10 to 0 in less than a second....

Script :

for i=10,1,-1 do
    print(i)
end
0
You're forgetting a "Wait(1)". You want the for loop to execute every 1 second so you wait that 1 second with "wait(1)" xPolarium 1388 — 9y

1 answer

Log in to vote
4
Answered by 9 years ago
for i=10,1,-1 do
    wait(1) -- this is very important. It puts a wait time in between each time it loops.
    print(i)
end
Ad

Answer this question