Skip to content

fix(game): make team colours actually visible - #36

Merged
ralyodio merged 1 commit into
mainfrom
fix/team-colours-readable
Jul 27, 2026
Merged

fix(game): make team colours actually visible#36
ralyodio merged 1 commit into
mainfrom
fix/team-colours-readable

Conversation

@ralyodio

Copy link
Copy Markdown
Contributor

Reported: "everything still looks the same to me." Correct, and here's why.

The bug

The team tint I added last time went through albedoColor — which multiplies the material's texture. The team band's texture is paint_red. Multiplying red by the friendly cyan gives ≈ black.

So the Directorate's red survived (it was already red) and Nightcell got an unlit dark band. Two teams, one visible colour — exactly the complaint the change was supposed to fix. It was a real bug, not just an over-subtle choice.

The fix

Multiplication can't produce a hue the source doesn't already contain, so the band now drops its texture and takes a flat colour. That's the only way to get saturated cyan out of a red source.

The band is also strongly emissive (0.85, up from 0.06). This is the one thing that must be legible across a dark yard at 40 m, and a diffuse surface at that range is a grey smudge whatever colour it is. Emissive pushes it over the scene's bloom threshold so the existing GlowLayer picks it up — that's what turns a colour into a marker. Cloth colours are pushed further apart too (cool blue-grey vs warm khaki) so silhouettes differ before the band resolves.

Verification

Screenshotted at gameplay distance rather than read off the diff: one figure now reads clearly cyan, the other clearly red, both across a dark yard.

Incidentally the same capture caught a bot's grenade detonating as a bright orange fireball — so the explosion VFX does render, and my earlier note that particles don't work in the headless renderer was wrong. That was the emission-window bug, since fixed.

249 tests pass; lint, typecheck and build clean.

🤖 Generated with Claude Code

Reported: "everything still looks the same to me." Correct, and this is why.

The team tint added last time was applied through `albedoColor`, which
*multiplies* the material's texture. The team band's texture is `paint_red`, so
multiplying it by the friendly cyan produced near-black: the Directorate's red
survived because it was already red, and Nightcell got an unlit dark band. Two
teams, one visible colour, no way to tell them apart — exactly the complaint
this was supposed to fix.

Multiplication cannot produce a hue the source does not already contain, so the
band now drops its texture and takes a flat colour instead. That is the only
way to get a saturated cyan out of a red source.

The band is also strongly emissive now (0.85, from 0.06). This is the one thing
that has to be legible across a dark yard at 40 m, and a diffuse surface at that
range is a grey smudge whatever colour it is. Emissive puts it over the scene's
bloom threshold so the existing GlowLayer picks it up, which is what turns a
colour into a marker. The cloth colours are pushed further apart too — cool
blue-grey against warm khaki — so the silhouettes differ before the band
resolves.

Verified by screenshot rather than by reading the diff: at gameplay distance one
figure now reads clearly cyan and the other clearly red.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

vu1nz Security Review

0 finding(s) in PR #?

No security issues found.

@ralyodio
ralyodio merged commit d3ad7af into main Jul 27, 2026
6 checks passed
@ralyodio
ralyodio deleted the fix/team-colours-readable branch July 27, 2026 04:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant