Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How the script failed?

Frame = game.StarterGui.ScreenGui.WarlandsGameInfo

function onClick()
	Frame.Visible = true
end

script.Parent.MouseButton1Click:connect(onClick)

WHen I click the button, nothing happens.

1 answer

✓ Accepted answer

Because you have to get all the players, it doesnt update, try this

Frame = ScreenGui.WarlandsGameInfo

function onClick()
   for k, p in pairs(game.Players:GetPlayers()) do
p.PlayerGui.Frame.Visible=true
end

script.Parent.MouseButton1Click:connect(onClick)

2 comments

0

Thanks. But what for k, p in pairs(game.Players:GetPlayers()) means?

This discussion is preserved as it was. New answers, comments, and votes are closed.