Hi there, I just made this mess of a script and of course, it doesn’t work. If anyone could help me clean it up or just help me fix the bug it would be appreciated. At the moment I have one of the skin colors equipped in the table so it should be printing “natural skin”.
Note: I’m very new to scripting and tables so sorry if this makes you cringe.
Script
local allowed = {
"234,184,146",
"204,142,105",
"175,148,131",
"124,92,70",
"90,76,66",
"86,66,54",
"105,64,40"
}
game.Players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(Character)
local character = player.Character
for x, c in pairs (allowed) do
if not c == character:WaitForChild("BodyColors").HeadColor3 or
character.BodyColors.RightArmColor3 or
character.BodyColors.RightLegColor3 or
character.BodyColors.LeftArmColor3 or
character.BodyColors.RightArmColor3 or
character.BodyColors.RightLegColor3 or
character.BodyColors.TorsoColor3
then
character.BodyColors.HeadColor3 = "234,184,146"
character.BodyColors.RightArmColor3 = "234,184,146"
character.BodyColors.RightLegColor3 = "234,184,146"
character.BodyColors.LeftArmColor3 = "234,184,146"
character.BodyColors.RightArmColor3 = "234,184,146"
character.BodyColors.RightLegColor3 = "234,184,146"
character.BodyColors.TorsoColor3 = "234,184,146"
else
print("natural skin")
end
end
end)
end)
Output:

