benilla-re systems structs docs

PackColourBytes

function · lighting · primitive

Address
0x6d5270 · 37 bytes, up to 0x6d5294
Meaning
Packs four bytes into a colour, the first on top
Confidence
verified, proof one
Finding
lighting/sky#sky-colours
Test
lighting::dn_pack_bytes_color_difftest

Finding: Sky colours in lighting: sky

The table build colours the dome each frame. With g the glow track times table +0x50, G[k] is band 2 + k moved toward band 3 by g, k = 1 to 4. The apex is band 2 through the HSV scale at 1.0. Ring k at column c takes band 2 + k varied by w, the dome track at phase heading/2π + 0.25 − c/24 wrapped into [0, 1): w ≥ 0 moves it toward G[k] by (1 − w)·g; w < 0 gives G[k] moved by −w·g toward G[k] moved toward band 2 by 0.7·g. The rim and one more colour are band 7. The rings take the screen tint (sky-colour-tracks).

The derivation is in the doc.

Callers 1

Callees 0

None by a direct call or jump.

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