while true do
local bob =script.Parent:Clone()
bob.Parent = workspace
wait(1)
end
When i ran the emulation, it just spawned 4 clones, waited and repeated. can someone fix it
while true do
local bob =script.Parent:Clone()
bob.Parent = workspace
wait(1)
end
When i ran the emulation, it just spawned 4 clones, waited and repeated. can someone fix it
Try a different type of loop.
for loop = 1, 4 do --Change the 4 to however many times it loops
local bob =script.Parent:Clone()
bob.Parent = workspace
wait(1)
end
If this isn't what you were looking for, I'm sorry. I wasn't quite sure what you wanted to do.
i wanted it to NOT loop, my script made it loop 4 times
Oh.. Well "While true" makes it loop
This discussion is preserved as it was. New answers, comments, and votes are closed.
3 comments
your code is fine, you probably have duplicate scripts or something
How many scripts with that code do you have wherever you have it located?
If you want it to stop stopping every one second, add wait() without the one, just leave it blank.