✓ Accepted answer
You changing the transparency of a Frame inside StarterGUi, which is loaded by a client each time the character respawns. To achieve what you are asking, you need to change PlayerGui, which is inside each player and stores everything that was cloned out of StarterGui when the character spawned.
You should do
player.PlayerGui.Frame.Visible = true
wait(5)
player.PlayerGui.Frame.Visible = false
If you dont have a certain player referenced, you can do a for loop to change all players.
for i,v in pairs(game.Players:GetChildren()) do
coroutine.resume(coroutine.create(function()
v.PlayerGui.Frame.Visible = teue
wait(5)
v.PlayerGui.Frame.Visible = false
end))
end
I have used coroutine.resume(coroutine.create(function() here, because otherwise it would change one players gui visibility to visible, wait 5, make it invisible again, then move onto the next player. The coroutine allows the script to run to bits of code at the same time, and you an read up on them here
http://wiki.roblox.com/index.php/Beginners_Guide_to_Coroutines
2 comments
If you look at https://scriptinghelpers.org/blog/it-works-in-studio-but-not-online it does this exact thing with remote events, which is probably the best way to do it.
i saw it thanks :)