ColorVector:Set(cr, cg, cb, ca)

Version added: before 9.5
Set the value of a color by r, g, b and a

Arguments:

Name Type Description Default Ver
cr real The r value you wish to set < 9.5
cg real The g value you wish to set < 9.5
cb real The b value you wish to set < 9.5
ca real The a value you wish to set 1.0 < 9.5

Return value:

void none
This function is an alternative to setting the R, G, B and A values individually. If you leave out the a value, it will default to 1.0.

Note that the values are real numbers 0-1, not integers 0-255.

For example:
local vc1 = LM.ColorVector:new_local()
vc1:Set(0, .995, 0, 1) -- almost pure green
<< Back to ColorVector