mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-15 08:34:40 +00:00
fixed the not working text edit RGB field on color picker.
This commit is contained in:
parent
df283a2709
commit
494922d9ed
1 changed files with 5 additions and 3 deletions
|
|
@ -879,9 +879,11 @@ DefineConsoleFunction(ColorHEXToRGB, ColorI, (const char* hex), ,
|
||||||
"@endtsexample\n"
|
"@endtsexample\n"
|
||||||
"@ingroup Strings")
|
"@ingroup Strings")
|
||||||
{
|
{
|
||||||
ColorI color;
|
S32 rgb = dAtoui(hex, 16);
|
||||||
color.set(hex);
|
|
||||||
return color;
|
ColorI color;
|
||||||
|
color.set(rgb & 0x000000FF, (rgb & 0x0000FF00) >> 8, (rgb & 0x00FF0000) >> 16);
|
||||||
|
return color;
|
||||||
}
|
}
|
||||||
|
|
||||||
DefineConsoleFunction(ColorHSBToRGB, ColorI, (Point3I hsb), ,
|
DefineConsoleFunction(ColorHSBToRGB, ColorI, (Point3I hsb), ,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue