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

waitTime Varible unable to go above the number 1?[solved]

Asked by 5 years ago
Edited 5 years ago

Ok I'm making a game where you have to pick coins up and get money the coins eventually respawn. But, in my part respawn script its unable to wait past 1. If you change it to 2 the script just wont work. Can anyone tell me what's going on here? Thanks!

model = script.Parent   
backup = model:clone()
waitTime = (1) -- wont go above


    wait(math.random(0,waitTime))
    while true do
        wait(waitTime)



        model:remove()



        model = backup:clone()
        model.Parent = workspace
        model:makeJoints()

    end     
0
Just change the number to be higher than 1? What do you mean it wont go above chomboghai 2044 — 5y
0
Sorry I should have been more specific, when you change it higher like 2 it wont respawm DatRainbowTee 49 — 5y
0
Don't use remove, it's deprecated. Use the Destroy() function instead. Pojoto 329 — 5y
0
ok DatRainbowTee 49 — 5y
0
Thank You So much! DatRainbowTee 49 — 5y

Answer this question