Skip to content

Constants

The globals the API defines next to its functions - the server’s colors without their alpha byte.

0xRRGGBB - red, green, blue; the alpha is apart (0 .. 100: SetUiAlpha, CreateUiRect’s own argument), because the game’s Lua keeps its numbers as 32-bit floats and a server-style 0xRRGGBBAA loses its last byte. Any number of that shape works wherever a color is taken (CreateUiText, CreateUiRect, SetUiColor).

Constant Value
COLOR_SERVER 0xFFD070 amber - the server’s own lines
COLOR_WHITE 0xFFFFFF
COLOR_RED 0xFF4040
COLOR_GREEN 0x40FF40
COLOR_YELLOW 0xFFFF40
COLOR_GOLD 0xF6E890 the game’s own text gold - the name plates, the HUD; the default of CreateUiText

Which edge of a text sits at its x (CreateUiText, SetUiAlign).

Constant Value
UI_ALIGN_LEFT 0
UI_ALIGN_CENTRE 1
UI_ALIGN_RIGHT 2

The look of the banner ShowObjectiveEvent shows.

Constant Value
OBJECTIVE_NEW 0 a new objective
OBJECTIVE_DONE 1 one completed
OBJECTIVE_FAILED 2 one failed