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

Error for my simple script?

Asked by
Relatch 550 Moderation Voter
10 years ago
h = Instance.new("Hint", game.Workspace)

while true do
    if game.Players.NumPlayers > 1 then
        h.Text = "Welcome to MrSmeny and MrSmenryBackup's Sword Fighting Tournament!"
        wait(3)
        h.Text = "The rules are simple, sword fight other people in duels and win!"
        wait(3)
        h.Text = "Please wait, loading map and deciding players."
        wait(3)
        h.Text = "This game is in beta, come back later."
    else
        h.Text = "There must be 2 or more players to start. Invite some friends."
    end
end

ERROR:

Game script timout; Line 4

Any help?

0
I see no error on line 4. Perci1 4988 — 10y

1 answer

Log in to vote
2
Answered by
RedCombee 585 Moderation Voter
10 years ago

I suggest adding a wait at the beginning of the loop.

Ad

Answer this question