When I write on a humanoid description
local humanoidDescription = Instance.new(“HumanoidDescription”)
humanoidDescription.LeftLegColor = Color3.new(255, 204, 153)
The color its blue (and not the default black so works), when if i put the same color (255, 204, 153) at easy interface of humanoid description element at workspace it is a skin color, I think function “color3” has something to do with this
Color3.new
takes arguments ranging from [0, 1]
, so Color3.new(1, 1, 1)
was the same as 255, 255, 255
. You will want to use Color3.fromRGB
which takes arguments ranging from [0, 255]
which is what you want.
2 Likes
If you still want to use Color3.new
, divide all the values by 255. That way, it will give you values ranging from 0~1 and is the correct way as well.
local color = Color3.new(37 / 255, 37 / 255, 37 / 255)
However as Incapaz said, you are better off using ``Color3.fromRGB`.
Or just have a function which checks if the values are higher than 1 and returns the divided values.
local function color3(a, b , c)
return a > 1 and a / 255 and b > 1 and b / 255 and c > 1 and c / 255
end
1 Like
Thanks Incapaz and Silents Replacement, I will give solution to incapaz because he reply first, but anyways, You also helped me, thanks.