Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How can i set a Color from a variable?

Im trying to save the players skin color,then change it to black and then change his skincolor back to the saved color.This is what i currently have:

if Value == "On" then
        script.Color.Value = Color3.fromRGB(char.Head.Color) --This is where it should save in a number value
        for i,part in pairs(char:GetChildren())do
				if part:IsA("MeshPart") then
					part.BrickColor = BrickColor.new("Really black")
		end
		end
		
		elseif Value == "Off" then
			local Part = player.Character.HumanoidRootPart
			local char = player.Character
	for i,part in pairs(char:GetChildren())do
		if part:IsA("MeshPart") then
		       part.Color = Color3.fromRGB(script.Color.Value) --Over here im setting it back
				end
		end	
end

1 answer

This discussion is preserved as it was. New answers, comments, and votes are closed.