ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. setSkyGradient

Function

setSkyGradient

Server and clientWorldIdentical to MTA:SA

Stores the sky colours: top (zenith) and bottom (near the horizon), each RGB 0-255.

Syntax

bool setSkyGradient([int topRed = 0, int topGreen = 0, int topBlue = 0, int bottomRed = 0, int bottomGreen = 0, int bottomBlue = 0])

Arguments

topRedint, optional = 0
Top red.
topGreenint, optional = 0
Top green.
topBlueint, optional = 0
Top blue.
bottomRedint, optional = 0
Bottom red.
bottomGreenint, optional = 0
Bottom green.
bottomBlueint, optional = 0
Bottom blue.

Returns

true on success.

Example

setSkyGradient(40, 0, 80, 255, 120, 40)

Notes

Client. In a client script - a value for this player only (resetSkyGradient goes back to the server one).

State for scripts. The game sky depends on time and weather; this value does not change it yet.

See also