I'm having problems with this script, Idk if im suppose to add a team and add the team color or what but I really need help please respond.
local plr = script.Parent.Parent.Parent.Parent.Parent.Parent -- Ascends the heirarchy and assigns a local variable to the player owning this GUI script.Parent.MouseButton1Click:connect(function() -- Activates when the GUI is clicked without the mouse leaving the button if plr:IsInGroup(755417) then -- Checks if the player is in UAF - Group ID is 80738 plr.TeamColor = game.Teams["Dark Assault Forces"].TeamColor -- If so, their Team colour is changed to the UAF Team colour local char = plr.Character.Humanoid -- Assigns a local variable to the players characters Humanoid if char then -- Checks if the character exists char.Health = 0 -- Sets the humanoid health to 0 (Kills them) end end end)
I tried it and all it does is not change my team here's the order: http://prntscr.com/8q107o