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

I made a Gui that appears/disappears depending on the team you are: not working?

Asked by
Tabrix 2
4 years ago

Hi, its the first time im posting here.

01local Players = game:GetService("Players")
02local frame = script.Parent
03local CameraPlayer = game.Players.LocalPlayer
04 
05game:GetService("Teams").Ingame.PlayerAdded:Connect(function(player)
06    player.CharacterAdded:Connect(function()
07        if player.Name == CameraPlayer.Name then
08            frame.Visible = false
09            CameraPlayer.CameraMode = Enum.CameraMode.LockFirstPerson
10            return
11        end
12    end)
13end)
14 
15game:GetService("Teams").Lobby.PlayerAdded:Connect(function(player)
View all 23 lines...

so when the team is assigned the gui is not going visible / not visible this is made on a localscript i debugged a bit and all looks correct (know that camera player stuff are working)

0
Manipulating GUIs require a localscript. Are you using it? Dovydas1118 1495 — 4y
0
its written... 'this is made on a localscript' Tabrix 2 — 4y
0
Are you trying to set their team at the start of the game, or between rounds? Nckripted 580 — 4y
0
between rounds Tabrix 2 — 4y

Answer this question