Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Text Color Change Question?

Asked by 5 years ago

script.Parent.MouseEnter:connect(function() script.Parent.RandomText.TextStrokeColor3 = Color3.new(53, 255, 110) end)

script.Parent.MouseLeave:connect(function() script.Parent.RandomText.TextStrokeColor3 = Color3.new(255, 255, 255) end)

Why does the color change to (13515, 65025, 28050) when my mouse enters the button and (65025, 65025, 65025) when my mouse leaves the button Instead of the numbers I specified?

1 answer

Log in to vote
0
Answered by 5 years ago

With Color3.new you have to divide each value (R, G, B) by 255 to get a semi-accurate color to what you want to achieve.

Instead, try changing 'Color3.new' to 'Color3.fromRGB' so you don't have to divide anything by 255 and it's much easier.

Ad

Answer this question