Hey everyone. What I'm trying to make it's so like the NPC evaluates the player torso's BrickColor for it add to the "allies" array. It doesn't seems to function but it doesn't results on an error either. I've trying to figure a way to do this.
Edit: I'm using R6 rigs for they are easier to work with
Here's the code:
game.Workspace.ChildAdded:Connect(function(char) if char.Name == game.Players:FindFirstChild(char.Name) then if char.Torso.BrickColor == BrickColor.new("Bright blue") then table.insert(allies,char.Name) else end end end)
If there's something I haven't seen or a better way to achieve this, please leave it on the comment section. All feedback is appreaciated.