You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
JoeStrout edited this page Nov 16, 2026
·
4 revisions
Get a color from a 32-bit integer value (0xRRGGBBAA)
Parameters
Parameter
Default Value
Note
hexValue
Return value
Condition
Return Value
(always)
map
Notes
In C, this function is used to load colors from a hexadecimal integer, like c = GetColor(0xFF0000FF) (representing opaque red in this example).
MiniScript does not have hexadecimal literals, so this is not a terribly useful function in raylib-miniscript. But it might be useful if reading a 4-byte value from a RawData, perhaps from a binary file or web request.
Example
// Build a color from a 4-byte binary valuebinaryValue=4278190335// decimal version of 0xFF0000FFc=raylib.GetColor(binaryValue)
printc// {"r": 255, "g": 0, "b": 0, "a": 255}