wolfGetRegionWeather
Wolf Territorieslist wolfGetRegionWeather()
This region's stored weather as key/value pairs, or an empty list.
Reads the region's weather as the same key/value list the setter takes, so a script can read it, change one value and hand the whole list straight back. Returns an empty list when the region has no weather record. The pairs come in this order, the same order as the rules table: "kind", "on", "level", "bright", "tint", "move", "density", "velocity", "size", "vol", "fog", "aurora", "colour", "sound", "amb", "near", "acol". "kind" and "on" are always there; any other key the region's record does not hold is left out, so find a value with llListFindList rather than by its position.
Takes no parameters.
The rules list
Key/value pairs in any order; the table lists them in the order wolfGetRegionWeather returns them. Every value is an integer percent except move, which is hundredths of a metre per second. An unknown key or an out-of-range value is refused, and wolfGetLastError says which.
| Key | Type | Values | Meaning |
|---|---|---|---|
| kind | string | clear, rain or snow | What falls. Required by both setters. "clear" on a parcel means no weather THERE even when the region is raining — a cave, a covered market. |
| on | integer | 0 or 1 | Region only. Whether the region weather is switched on. A script that sets a kind turns it on unless it says otherwise. |
| level | integer | 1 – 4 | How heavy: 1 light, 2 moderate, 3 heavy, 4 torrential rain / blizzard. The level sets the base particle count and fall speed the other percentages scale. |
| bright | integer | 0 – 200 (%) | Brightness of the precipitation's lit colour. 100 is neutral. |
| tint | integer | 0 – 100 (%) | How far from the kind's neutral colour towards the tint colour. |
| move | integer | 0 – 1000 (hundredths m/s) | Sideways drift the weather leans on. 60 = 0.60 m/s. The direction turns slowly on its own. |
| density | integer | 10 – 4000 (%) | Particle count as a percentage of the level's own figure. Source: Wolf_Api.cs WEATHER_RANGES, the Weather tab's own range since 2026-09-18. |
| velocity | integer | 10 – 300 (%) | Fall speed as a percentage of the level's own figure. |
| size | integer | 10 – 400 (%) | Particle size as a percentage of the kind's own width. |
| vol | integer | 0 – 100 (%) | Weather sound volume. |
| fog | integer | 0 – 100 (%) | Thick air, 0 = none. Independent of the kind: fog with rain, with snow, or on its own under "clear". The number is a visibility: 2000 m × 0.02^(fog/100), so 50 is about 280 m and 100 is 40 m. |
| aurora | integer | 0 – 100 (%) | The northern lights, 0 = none. Night only: the viewers fade it in after dusk and out at dawn, so a script may leave it set all winter. 35 is a faint arc, 70 bright curtains, 100 a storm overhead. |
| colour | string | #rrggbb | The tint colour ("color" is accepted too). Rain's neutral is #aaccff, snow's is #ffffff. |
| sound | integer | 0 or 1 | Whether the weather makes any sound at all. |
| amb | string | none, thunder, steady, wind, distant | The ambience bed. "thunder" and "distant" are storms: they fork lightning and roll thunder in both viewers. |
| near | string | none, soft, heavy, leaves, water | The near layer — the sound of rain on what is around you. |
| acol | string | green, red, purple, blue, pink, multi | The aurora's colour. "multi" cycles through them. |
Example
default
{
touch_start(integer n)
{
list w = wolfGetRegionWeather();
llOwnerSay("Weather now: " + llDumpList2String(w, " "));
// Make it one level heavier, keeping everything else as it is.
integer i = llListFindList(w, ["level"]);
if (i != -1)
{
integer level = llList2Integer(w, i + 1);
if (level < 4) w = llListReplaceList(w, [level + 1], i + 1, i + 1);
wolfSetRegionWeather(w);
}
}
}Ours alone. Grid features you will not find on any other OpenSimulator grid.