Color

Displays color.

# Properties

[{"index":"float a","0":"The elements of the transparency of colors. 0 is transparent, 1 is opaque."}]

[{"index":"float b","0":"The elements of the color blue."}]

[{"index":"float g","0":"The elements of the color green."}]

[{"index":"float r","0":"The elements of the color red."}]

[{"index":"Color black (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use black (0, 0, 0, 1)."}]

[{"index":"Color blue (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use blue (0, 0, 1, 1)."}]

[{"index":"Color clear (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use transparent (0, 0, 0, 0)."}]

[{"index":"Color cyan (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use jade (0, 1, 1, 1)."}]

[{"index":"Color gray (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use grey (0.5, 0.5, 0.5, 1)."}]

[{"index":"Color green (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use green (0, 1, 0, 1)."}]

[{"index":"Color magenta (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use magenta (1, 0, 1, 1)."}]

[{"index":"Color red (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use red (1, 0, 0, 1)."}]

[{"index":"Color white (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use white (1, 1, 1, 1)."}]

[{"index":"Color yellow (Static) (ReadOnly) (HideFromInspector)","0":"You can simply use yellow (1, 0.92, 0.016, 1)."}]

# Constructors

[{"index":"Color(float r, float g, float b)","0":"Initializes to the specified r, g, b values."}]

[{"index":"Color(float r, float g, float b, float a)","0":"Initializes to the specified r, g, b, a values."}]

# Methods

[{"index":"Color Clone()","0":"Generates a copy."}]

[{"index":"float Grayscale()","0":"Finds the grayscale of the color."}]

[{"index":"Color Lerp(Color b, float t)","0":"Creates a Color value using linear interpolation with t between two Colors and returns it. The t value is fixed between 0 and 1."}]

[{"index":"Color LerpUnclamped(Color b, float t)","0":"Creates a Color value using linear interpolation with t between two Colors and returns it."}]

[{"index":"float, float, float RGBToHSV()","0":"Converts the RGB value to HSV and returns it."}]

[{"index":"string ToHexCode()","0":"Converts RGBA to hex code."}]

[{"index":"integer ToRGBAInt()","0":"Converts RGBA to an integer. Uses the '0xFFFFFFFF' format."}]

[{"index":"Color FromHexCode(string hexCode) (Static)","0":"Creates a Color entity using the hexadecimal number color value hex code. Uses a format such as #FFFFFF."}]

[{"index":"Color FromRGBAInt(integer rgba) (Static)","0":"Creates a Color entity using the RGBA represented as an integer."}]

[{"index":"float Grayscale(Color color) (Static)","0":"Finds the grayscale of the color."}]

[{"index":"Color HSVToRGB(float h, float s, float v) (Static)","0":"Converts and returns the HSV value to RGB. The RGB value is fixed between 0 and 1."}]

[{"index":"Color HSVToRGB(float h, float s, float v, boolean hdr) (Static)","0":"Converts and returns the HSV value to RGB. If hdr is true, the RGB value is not fixed between 0 and 1."}]

[{"index":"Color Lerp(Color a, Color b, float t) (Static)","0":"Creates a Color value using linear interpolation with t between two Colors and returns it. The t value is fixed between 0 and 1."}]

[{"index":"Color LerpUnclamped(Color a, Color b, float t) (Static)","0":"Creates a Color value using linear interpolation with t between two Colors and returns it."}]

[{"index":"float, float, float RGBToHSV(Color rgbColor) (Static)","0":"Converts the RGB value to HSV and returns it."}]

[{"index":"string ToHexCode(Color color) (Static)","0":"Converts RGBA to hex code."}]

[{"index":"integer ToRGBAInt(Color color) (Static)","0":"Converts RGBA to an integer. Uses the '0xFFFFFFFF' format."}]

# Operators

[{"index":"Color Addition(Color left, Color right) (Static)","0":"Returns a new Color entity by adding the two specified values together. The calculation result is Color(left.r + right.r, left.g + right.g, left.b + right.b, left.a + right.a)."}]

[{"index":"Color Division(Color left, float right) (Static)","0":"Returns a new Color entity by dividing the specified value by the real number. The calculation result is Color(left.r \/ right, left.g \/ right, left.b \/ right, left.a \/ right)."}]

[{"index":"boolean Equality(Color left, Color right) (Static)","0":"Checks if the two values are the same. Returns true if all values are the same. Otherwise, returns false."}]

[{"index":"boolean Inequality(Color left, Color right) (Static)","0":"Checks if the two values are different. Returns false if all values are the same. Otherwise, returns true."}]

[{"index":"Color Multiply(Color left, Color right) (Static)","0":"Returns a new Color entity by multiplying the two specified values together. The calculation result is Color(left.r * right.r, left.g * right.g, left.b * right.b, left.a * right.a)."}]

[{"index":"Color Multiply(Color left, float right) (Static)","0":"Returns a new Color entity by multiplying the specified value by the real number. The calculation result is Color(left.r * right, left.g * right, left.b * right, left.a * right)."}]

[{"index":"Color Multiply(float left, Color right) (Static)","0":"Returns a new Color entity by multiplying the specified value by the real number. The calculation result is Color(left * right.r, left * right.g, left * right.b, left * right.a)."}]

[{"index":"Color Subtraction(Color left, Color right) (Static)","0":"Returns a new Color entity by subtracting the specified right value from the left value. The calculation result is Color(left.r - right.r, left.g - right.g, left.b - right.b, left.a - right.a)."}]