If the part "Ifred" is = red then it should be removing my head but it dosen't work, what did i do wrong?
(Inside a tool, localscript, the brick is called "Ifred")
script:
script.Parent.Activated:Connect(function() if workspace.IfRed == BrickColor.new("Really red") then game.Players.LocalPlayer.Character.Head:Remove() else print("Nope it's not red, puh") end end)
i tried if workspace.IfRed == BrickColor = BrickColor.new("Really red") but that wont work.
Help would be appreciated!
script.Parent.Activated:Connect(function() if workspace.IfRed.BrickColor == BrickColor.new("Really red") then game.Players.LocalPlayer.Character.Head:Remove() else print("Nope it's not red, puh") end end)
If this is a local script, this works. If this is a normal script. This needs to be there instead.
script.Parent.Activated:Connect(function() if workspace.IfRed == BrickColor.new("Really red") then script.Parent.Parent.Head:Remove() else print("Nope it's not red, puh") end end)