plr = game.Players.LocalPlayer
chr = plr.Character
mouse = plr:GetMouse()
while true do
eye = script.Parent.EyeColor
skin = script.Parent.SkinTone
gender = script.Parent.Gender
hair = script.Parent.Hair
--eyecolor
if eye.Blue.MouseButton1Click == true then
chr.Head.LeftEye.Decal.Color3 = eye.Blue.BackgroundColor3
chr.Head.RightEye.Decal.Color3 = eye.Blue.BackgroundColor3
end
if eye.Grey.MouseButton1Click == true then
chr.Head.LeftEye.Decal.Color3 = eye.Grey.BackgroundColor3
chr.Head.RightEye.Decal.Color3 = eye.Grey.BackgroundColor3
end
if eye.Hazel.MouseButton1Click == true then
chr.Head.LeftEye.Decal.Color3 = eye.Hazel.BackgroundColor3
chr.Head.RightEye.Decal.Color3 = eye.Hazel.BackgroundColor3
end
if eye.Green.MouseButton1Click == true then
chr.Head.LeftEye.Decal.Color3 = eye.Green.BackgroundColor3
chr.Head.RightEye.Decal.Color3 = eye.Green.BackgroundColor3
end
if eye.Brown.MouseButton1Click == true then
chr.Head.LeftEye.Decal.Color3 = eye.Brown.BackgroundColor3
chr.Head.RightEye.Decal.Color3 = eye.Brown.BackgroundColor3
end
--skintone
if skin.Lightest.MouseButton1Click == true then
chr.Head.Color = skin.Lightest.BackgroundColor3
chr.LeftLowerArm.Color = skin.Lightest.BackgroundColor3
chr.RightLowerArm.Color = skin.Lightest.BackgroundColor3
end
if skin.Light.MouseButton1Click == true then
chr.Head.Color = skin.Light.BackgroundColor3
chr.LeftLowerArm.Color = skin.Light.BackgroundColor3
chr.RightLowerArm.Color = skin.Light.BackgroundColor3
end
if skin.Middle.MouseButton1Click == true then
chr.Head.Color = skin.Middle.BackgroundColor3
chr.LeftLowerArm.Color = skin.Middle.BackgroundColor3
chr.RightLowerArm.Color = skin.Middle.BackgroundColor3
end
if skin.Dark.MouseButton1Click == true then
chr.Head.Color = skin.Dark.BackgroundColor3
chr.LeftLowerArm.Color = skin.Dark.BackgroundColor3
chr.RightLowerArm.Color = skin.Dark.BackgroundColor3
end
if skin.Darkest.MouseButton1Click == true then
chr.Head.Color = skin.Darkest.BackgroundColor3
chr.LeftLowerArm.Color = skin.Darkest.BackgroundColor3
chr.RightLowerArm.Color = skin.Darkest.BackgroundColor3
end
wait()
end
This script should allow me to change the eye color and skin tone of a custom character I created. I have 10 gui buttons, 5 for eye color and 5 for skin tone. It is not changing though, what should I do?
It is a Script in the Frame of the gui

1 comment
mousebutton1click cannot be used in an if statement