KvGetColor Function

Retrieves a set of color values from a KeyValues key.

void KvGetColor(Handle kv, const char[] key, int& r, int& g, int& b, int& a)

Parameters

Handle kv

KeyValues Handle.

const char[] key

Name of the key, or NULL_STRING.

int& r

Red value, set by reference.

int& g

Green value, set by reference.

int& b

Blue value, set by reference.

int& a

Alpha value, set by reference.

Errors

Invalid Handle.