Skip to content

static class Sky (client-side)

Available since version: 0.1.6

This class represents in game Sky.

Properties

int weather

Available since version: 0.1.10

Represents the sky weather. For more information see Weather constants.


bool dontRain

Available since version: 0.1.10

Represents the sky dontRain feature.
When it's enabled, the rain/snow won't fall.


bool darkSky

Available since version: 0.1.10

Represents the dark sky feature. When it's enabled, the sun clouds are dark.


Methods

setWeather

Deprecated since version: 0.1.10

This method will set the sky weather.

void setWeather(int weather)

Parameters:

  • int weather: the sky weather.

getWeather

Deprecated since version: 0.1.10

This method will get the sky weather.

int getWeather()

Returns int:

the sky weather.


setDontRain

Deprecated since version: 0.1.10

This method will enable/disable don't rain option for the sky.

void setDontRain(bool toggle)

Parameters:

  • bool toggle: true if you want to disable rainining/snowing, otherwise false.

isDontRain

Deprecated since version: 0.1.10

This method will check if don't rain option is enabled for the sky.

bool isDontRain()

Returns bool:

true if rainining/snowing is disabled, otherwise false.


setDarkSky

Deprecated since version: 0.1.10

This method will enable/disable dark sky feature.
When it's enabled, the sun clouds are dark.

void setDarkSky(bool toggle)

Parameters:

  • bool toggle: true if you want to enable dark sky, otherwise false.

isDarkSky

Deprecated since version: 0.1.10

This method will check if dark sky option is enabled.

bool isDarkSky()

Returns bool:

true if dark sky option is enabled, otherwise false.


setFogColor

Available since version: 0.1.6

This method will set the sky fog color.

void setFogColor(int r, int g, int b)

Parameters:

  • int r: the red color component in RGB model.
  • int g: the green color component in RGB model.
  • int b: the blue color component in RGB model.

setCloudsColor

Available since version: 0.1.6

This method will set the sky clouds color.

void setCloudsColor(int r, int g, int b)

Parameters:

  • int r: the red color component in RGB model.
  • int g: the green color component in RGB model.
  • int b: the blue color component in RGB model.

setPlanetSize

Available since version: 0.1.6

This method will set the planet size ratio.

void setPlanetSize(int planetId, float size)

Parameters:

  • int planetId: the planet id, for more information see Planet constants.
  • float size: the size ratio.

setPlanetColor

Available since version: 0.1.6

This method will set the planet color.

void setPlanetColor(int planetId, int r, int g, int b, int a)

Parameters:

  • int planetId: the planet id, for more information see Planet constants.
  • int r: the red color component in RGBA model.
  • int g: the green color component in RGBA model.
  • int b: the blue color component in RGBA model.
  • int a: the alpha color component in RGBA model.

setLightingColor

Available since version: 0.1.6

This method will set the sky lighting color.

void setLightingColor(int r, int g, int b)

Parameters:

  • int r: the red color component in RGB model.
  • int g: the green color component in RGB model.
  • int b: the blue color component in RGB model.