Replies with the current value of one environment (EEP sky) parameter. Values are scaled to match the ranges @setenv_ accepts, so a script can read a value, change it, and write it back. Reading is always allowed: neither @setenv nor RestrainedLoveNoSetEnv blocks it.

Syntax

@getenv_<setting>=<channel>

Parameters

Settings read from the current sky (Marine's viewer). "x ÷ 2" means the internal value divided by 2, and so on. Triplet settings reply r;g;b or x;y;z, separated by semicolons.

Setting(s)Reply
daytimeDeprecated. -1 if no preset has been loaded through RLV this session, otherwise 1 if the sun is above the horizon and 0 if below.
preset, assetName of the last preset or asset loaded via @setenv_preset/asset (empty if none)
bluehorizon[r|g|b|i], bluedensity[r|g|b|i]Color component ÷ 2. i = max of the three ÷ 2. No suffix = triplet.
sunmooncolor[r|g|b|i], sunlightcolor[…]Sunlight color ÷ 3 (same conventions)
ambient[r|g|b|i]Ambient color ÷ 3
cloudcolor[r|g|b|i]Cloud color, unscaled
cloud[x|y|d], clouddensity[x|y|d]Cloud position/density 1
clouddetail[x|y|d]Cloud position/density 2
cloudscroll[x|y]Scroll rate − 10 (triplet form gives x;y)
cloudcoverage, cloudscale, cloudvarianceRaw values
hazehorizon / hazedensityRaw / ÷ 4
densitymultiplier / distancemultiplier / maxaltitude× 1000 / raw / raw
sunglowfocus / sunglowsize−glow.z ÷ 5 / 2 − glow.x ÷ 20
scenegammaGamma mapped back to the 0-20 @setenv_scenegamma scale
starbrightness, moisturelevel, dropletradius, icelevel, sunscale, moonscale, moonbrightnessRaw values
sunazim[uth], moonazim[uth]Yaw of the sun/moon rotation, radians
sunelev[ation], moonelev[ation]Elevation, radians
eastangleeastangle;sunmoonposition, both 0-1
sunmoonpositionsunmoonposition;eastangle, both 0-1
sunimage/suntexture, moonimage/moontexture, cloudimage/cloudtextureTexture UUIDs

Return value

Numbers in default C++ stream formatting (up to 6 significant digits, e.g. 0.25, 1e-05). An unknown setting gives an empty reply in Marine's viewer and 0 in CoolVL.

Caveats

Examples

llOwnerSay("@getenv_ambient=81234");     // e.g. "0.333333;0.333333;0.333333"
llOwnerSay("@getenv_eastangle=81234");   // e.g. "0.25;0.6"

See also

Implementation notes

Dispatch: RRInterface.cpp 1865. getEnvironment() 4991-5226 reads LLEnvironment::instance().getCurrentSky(). The eastangle/sunmoonposition conversion uses convert_direction_to_azimuth_and_elevation() (163-300), which falls back to the last values written by @setenv in degenerate cases. The scenegamma reverse mapping is at 5068-5100.

Client differences

Comparison with RLVa

This command works differently from RLVa's @getenv_; see the comparison.