GetWaterColor

From Multi Theft Auto: Wiki
Revision as of 20:32, 25 June 2011 by Kamek (talk | contribs) (→‎Example)
Jump to navigation Jump to search

This function returns the water color of the GTA world.

Note: The server can only return the water color, if it has actually been set by script.

Syntax

int, int, int, int getWaterColor ( )

Returns

Returns 4 ints, indicating the color of the water. (RGBA)

Example

function getWaterColor ( command ) --start function
	local color = getWaterColor() -- color as getWaterColor
	outputChatBox( "Water color is " .. color .. " !", source ) --outputchatbox for water color
end
addCommandHandler( "getwatercolor", getWaterColor ) --add a command "getwatercolor"

See Also