GetPropertyChangedSignal ("Team") not firing ever

Ive been trying to make GUI hide when a player is not on the “Lobby” Team, The problem is that the GetPropertyChangedSignal Doesnt fire when its supposed to.

local Lobby = game:GetService("Teams"):WaitForChild("Lobby")
local Nato = game:GetService("Teams"):WaitForChild("Nato")
local Warsaw = game:GetService("Teams"):WaitForChild("Warsaw Pact")


PLR:GetPropertyChangedSignal("Team"):Connect(function()
		task.wait (0.5)
		if PLR.Team == Lobby then  PLR.PlayerGui.LobbyGUI.Enabled = true print "hi"
			if PLR.Team == Nato then PLR.PlayerGui.LobbyGUI.Enabled = false print "hi"
				if PLR.Team == Warsaw then PLR.PlayerGui.LobbyGUI.Enabled = false print "hi"
	end
	end
		end
		end)
``` Doesnt print or change the guis visibility.
1 Like

you don’t have to use :GetPropertyChangedSignal() on a team change, use team.PlayerAdded:Connect(function(PlayerThatWasAddedToThatSpecificTeamAtSomePointInTime) end)

on a side note, i love the indentation, and script logic itself! did you follow this awesome tutorial?

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.