(info) This AI is still in early stages of development.

Sun & Moon

Big shiny things in the sky...

 

Position

The position of the sun and moon is determined by the following factors:

  • Date / Time
  • Geolocation of map (latitude and logitude)

Sun position

A BSD-licensed (open source) script, suncalc, calculates the position in terms of altitude and azimuth (see diagram below) and then the Nature API converts those values to Warzone's co-ordinate system.

Day / Night cycle

The day/night cycle is disabled by default.

To enable the cycle, set the night time multiplier to a positive number, where the number specifies the number of gameTime milliseconds per virtual hour to apply during the night (the period between dusk and dawn). The multiplier allows you to skew the amount of time spent in darkness in proportion to the time spent during daytime.

Sun colours

The colour of the sun can be varying shades of white, yellow or orange.

Pro tip: Red sky at night, Commander's delight. Red sky in morning, Commander's warning.

Moon colours

"Pale moon rains; Red moon blows.
White moon neither rains nor snows." 

Dust particles in the atmosphere cause rain to form, they also cause the moon to appear pale or reddish-orange.

Halos

"When halo rings the moon or sun, rain's approaching on the run..."

Sun halos and moon rings often occur in the presence of cirrostratus nebulosus clouds, and are often a sign of approaching storms.

In the coldest days of winter, a halo around the sun is evidence of very cold and typically clear air at and above the surface.

In the case of moon rings, they usually occur during or near full moon and are roughly 10 to 20 times the size of the moon.

Arcs

A circumzenithal arc will often be present when Cirrus clouds appear near the zenith overhead (roughly 12,000m altitude in this case) and the sun is at an altitude between 0º and 32.2º from the horizon.

The circumzenithal arc is brightest when the sun is at 22º above the horizon, and fades away in either direction.

When the sun is above 32.2º, a colourless parhelion may be observed.

Sundogs (Parhelions)

Sundogs, sometimes called "mock suns", are extreme forms of sun halos. They appear in the presence of Cirrus clouds when the sun is close to the horizon, and indicate a change in weather conditions within the next 18 to 36 hours.

During very cold weather they can be caused by "diamond dust", tiny ice crystals floating in the air at low level, and indicate the approach of snow and blizzards.

As the sun gets higher, the sundogs move further from the sun and become smaller and fainter, eventually disappearing. They are always horizontally aligned with the sun.

Rainbows

Rainbows always appear in the section of sky directly opposite to the sun.

A rainbow in the morning (appearing in the west) indicates an approaching storm. A rainbow in the evening (appearing in the east) indicates the storm has passed.

Light pillars

Light pillars form when the sun or moon is close to the horizon.

Moon phases

Moon phase is automatically calculated based on date and geolocation of map. Visibility of the moon is determined by time of day and moon phase.

For sake of simplicity, the moon is depicted as if viewed from the equator over a period of 29.5 days during October and November 2007 (source). The depicted surface of the moon and it's libration does not change based on map geolocation or date.