DoRGBaValue
Category:
Arithmetics
Since engine version:
5.1 OC
Description
Adds a specified color value to a 32 bit color value.
select
Selection
0
Alpha value
1
Red value
2
Green value
3
Blue value
Syntax
int
DoRGBaValue(
int
Val,
int
change,
int
select);
Parameters
Val:
32 bit color value
change:
Color value to be added.
select:
0-3: Color value to be changed.
Remark
This function does not ensure maximum or minimum limits of color values.
Example
GetCursor
()->SetColor(DoRGBaValue(
GetCursor
()->
GetColor
(),-20,1));
Reduces the red part of the currently selected clonk by 20.
See also:
GetRGBaValue
,
SetRGBaValue
Tyron, 2004-08