Skip to content

Fix #172: hitbox trail entries now store deterministic size + isWave#178

Open
Tekkra-Pi wants to merge 1 commit into
web-dashers:mainfrom
Tekkra-Pi:fix/hitbox-history-immutable
Open

Fix #172: hitbox trail entries now store deterministic size + isWave#178
Tekkra-Pi wants to merge 1 commit into
web-dashers:mainfrom
Tekkra-Pi:fix/hitbox-history-immutable

Conversation

@Tekkra-Pi

Copy link
Copy Markdown

Root Cause

Hitbox trail rendering read this.p.isMini and this.p.isWave (current live state) for all historical entries, causing past trail entries to retroactively change size/shape when the player switched gamemodes (cube ↔ mini wave).

Fix

  • Push (game-scene.js:6081): store pre-computed size (18 or 30) and isWave per trail entry at record time
  • Render (player.js:2669-2706): use stored pos.size and pos.isWave instead of live state

Trail entries are now fully deterministic — past frames are immutable regardless of current gamemode.

Testing

  • Toggled cube ↔ mini wave repeatedly
  • Confirmed past trail entries do NOT change retroactively
  • Current hitbox still matches live gamemode correctly

…l entries

Trail rendering was reading this.p.isMini and this.p.isWave (current
live state) when drawing historical hitbox trail entries, causing past
entries to retroactively change size/shape on gamemode transition.

Fix:
- Push: store pre-computed size (18/30) and isWave per trail entry
- Render: use stored pos.size and pos.isWave instead of live state

Hitbox trail is now fully deterministic per frame.
@lasokar

lasokar commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

You saved us all with this life changing pr

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.

3 participants