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

Wait() Being Random?

Asked by 6 years ago
Edited 6 years ago

I am trying to have a block when you press "E" it disappears waits 20 seconds and reappears ready to be picked up again. But it appears my script is being random without using math.random. I would like it to just be 20 seconds. I don't know much about part regeneration and would like to know what's causing the problem so I can fix it. This is a server script should it be local idk. Thanks!

01local model = script.Parent
02 
03 
04if model ~= workspace then
05 
06    local backup = model:clone()
07 
08    while true do
09        wait(20)
10 
11        model:Destroy()
12 
13 
14 
15        model = backup:clone()
View all 21 lines...

Answer this question