QcWeatherState Struct
The weather of a world as world.json keeps it (decision E-395): the current spell (kind and the ticks until it ends), how many spells the world has had, the strengths of rain and thunder, which fade towards the spell's kind, and how many ticks the weather has run. More...
| Header: | #include <common/world/QcWeather.h> |
Public Variables
Related Non-Members
| enum class | QcPrecipitation { None, Rain, Snow } |
| enum class | QcWeatherKind { Clear, Rain, Thunder } |
Detailed Description
Member Variable Documentation
QcWeatherKind QcWeatherState::kind
The kind of the current spell.
qint64 QcWeatherState::spell
Spells so far; with the seed it decides the next spell. 0: the world's first spell has not begun (a new world, or one saved without weather), the first tick starts a clear one.
qint64 QcWeatherState::ticks
Ticks the weather has run (world.json "ticks", 0 when missing). With the seed it decides the random draws of each tick (strikes, snowfall; QcWeatherCycle::Draws), so they go on after loading as if the world had not been saved (decision E-397).
qint64 QcWeatherState::ticksLeft
Ticks until the spell ends while the game rule weatherCycle is on.
Related Non-Members
enum class QcPrecipitation
What falls at one place while it rains: nothing (a dry biome, or no rain at all), rain or snow.
| Constant | Value | Description |
|---|---|---|
QcWeatherState::QcPrecipitation::None | 0 | Nothing falls. |
QcWeatherState::QcPrecipitation::Rain | 1 | Rain falls. |
QcWeatherState::QcPrecipitation::Snow | 2 | Snow falls. |
enum class QcWeatherKind
What the sky does in the whole world (decision E-395): clear, rain (snow where it is cold) or a thunderstorm, which rains as well.
| Constant | Value | Description |
|---|---|---|
QcWeatherState::QcWeatherKind::Clear | 0 | Clear sky. |
QcWeatherState::QcWeatherKind::Rain | 1 | Rain. |
QcWeatherState::QcWeatherKind::Thunder | 2 | A thunderstorm. |