Summary
My script is supposed to check if a player is a certain team to prevent players from going into the opposite teams base, but it just throws a error and does nothing.
Error
Team is not a valid member of player
Script
script.Parent.Touched:connect(function(hit)
local player = game.Players:GetPlayerFromCharacter(hit.Parent)
if player.Team == "Bright red Team" then
player:BreakJoints()
end
end)

1 comment
updated