benilla-re systems structs docs

CWorld::SetFogState

function · terrain · host

Address
0x66ff20 · 56 bytes, up to 0x66ff57
Signature
void __cdecl (void)
Meaning
Sets the device fog states from the current light state
Confidence
verified, proof one
Finding
lighting/fog#fog-states

Finding: Fog states in lighting: fog and the world light

0x66ff20 commits the scene fog to the device: start, end and colour as fog states 0xa, 0xb and 0xd. The start goes as it is, so a negative start fraction in a light record fogs the near field too. The map object batches commit the interior-blended fog +0x84, +0x88 and +0x80 the same way, and a material with flag 0x20 draws with the window colours: the device light's diffuse takes +0x17c and its ambient +0x180, and both return to diffuse and ambient after the batch.

The derivation is in the doc.

Callers 1

Callees 3

Calls and jumps by a bare address, from tables/calls.tsv.