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

I need help with this script please?

Asked by
Myuuckn -5
10 years ago

Please make your question title relevant to your question content. It should be a one-sentence summary in question form.
Player = game.Players:GetChildren()
Sword = game.Lighting.LinkedSword:Clone()
while true do
PlayerChosen = math.random (1, #Player)
PlayerChosenBackpack = PlayerChosen.Backpack
Sword.Parent = PlayerChosenBackpack 
end

1 answer

Log in to vote
0
Answered by
Emg14 10
10 years ago

A warning of using while loops:

Doing this:while true do --stuff to do end will error. To fix it just add a wait()

Ad

Answer this question