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

GUI only visible for a certain team? [SOLVED] (THANK YOU!)

Asked by
Oficcer_F 207 Moderation Voter
5 years ago
Edited 5 years ago

PROBLEM: GUI becomes invisible after player dies. NEED HELP FOR: Making it visible after the player dies again. NOTES: Is there another way then to copy the GUI into the players StarterGui?

Server script:

player = game.Teams.Inferno:GetPlayers()
inferno = game.Teams.Inferno
wave = game.Teams.Wave
game.Players.PlayerAdded:Connect(function(player)

if player.Team == inferno then
    game.ReplicatedStorage.MakeVisible:FireAllClients(player)
elseif player.Team == wave then
    game.ReplicatedStorage.MakeVisibleBlue:FireAllClients(player)
end

end)

Local script:

game.ReplicatedStorage.MakeVisibleBlue.OnClientEvent:Connect(function(player)

    player.PlayerGui.ScreenGui.BlueUpgradeGui.Visible = true
    player.PlayerGui.ScreenGui.BlueUpgradeGui.Active = true


end)

Thank you for help! Tell me if there is NO OTHER way then to copy it to the playerGui...

0
Do it from client side OBenjOne 190 — 5y
1
actually, there should be a property in the GUI. Resetonspawn I think. set that to false and you should be good to go OBenjOne 190 — 5y
0
yeah, what Phlegethon5778 said OBenjOne 190 — 5y
0
AAAAAAAAAAAH, THANK YOU SO MUCH GUYS!! Oficcer_F 207 — 5y

Answer this question