✓ Accepted answer
Hey!
The Issue
The basic issue is that players is an array, so of course it is not going to work. I don't usually use this kind of loop when doing this kind of thing, I like to use pairs.
Approach
I would approach it like this:
for _,player in pairs(game.Players:GetChildren()) do
player.PlayerGui.InformationGui.maintext.Text = "Example"
end
Or you could approach it like this (source):
local plrs=game.Players:GetPlayers()
for i=1,#plrs do
output=plrs[i].PlayerGui.InformationGui.maintext.Text = "Example"
end
Thanks
Thanks for reading my answer! I hope it helped.
~NowUndoThatMistake