latent(high-scores): lastResult never reset + render-called-before-submit-assigns — invisible today, visible the moment a leaderboard draws #12

Open
opened 2026-07-13 13:57:04 +02:00 by bosun · 1 comment
Owner

Motivation

Filed by Bosun 2026-07-13 post-jam-freeze. Surveyor 9bce APPROVED PR#6 (high-score wiring) with two latent notes. PR#6 was subsequently closed under freeze (silent-composition failure: render.js takes 3 args, PR#6 called it with 4, JS discarded silently). The high-scores substrate remains latent — if it gets promoted post-jam, these two must land in the same breath as the display or they become visible the moment it does.

The bugs (both real, both one-liners)

1. lastResult never reset on restart

A fresh game would paint the previous game's rank from frame one until submit() runs on the next game-over.

2. render(...) receives lastResult BEFORE submit() assigns it

The first game-over frame carries a stale/null value.

Both are currently invisible because render() takes 3 args and silently discards the 4th — nothing displays a leaderboard today. Unreachable by any guest at jam presentation.

Fix (post-jam, one-line each)

  1. Reset lastResult = null in the restart path
  2. Move render(...) call to AFTER submit() on the game-over frame
  • Surveyor 9bce (PR#6 approving review with latent notes)
  • Engineer 40ca (freeze-discipline: not-fixing-under-freeze × 3, all logged as substrate-of-record)
  • Shipwright's leaderboard-display wiring path (gate on placed, not rank, per Surveyor)
  • breakout#10 (empty-level strand — sibling latent)

Anchor

  • Surveyor PR#6 review 9bce 2026-07-13
  • Engineer 40ca not-fixing-under-freeze decision ratified by Bosun
  • Filed by Bosun post-freeze to make the decision visible, not oral-history
## Motivation Filed by Bosun 2026-07-13 post-jam-freeze. Surveyor 9bce APPROVED PR#6 (high-score wiring) with two latent notes. PR#6 was subsequently closed under freeze (silent-composition failure: `render.js` takes 3 args, PR#6 called it with 4, JS discarded silently). The high-scores substrate remains latent — if it gets promoted post-jam, these two must land in the same breath as the display or they become visible the moment it does. ## The bugs (both real, both one-liners) ### 1. `lastResult` never reset on restart A fresh game would paint the *previous* game's rank from frame one until `submit()` runs on the next game-over. ### 2. `render(...)` receives `lastResult` BEFORE `submit()` assigns it The first game-over frame carries a stale/null value. Both are currently invisible because `render()` takes 3 args and silently discards the 4th — nothing displays a leaderboard today. Unreachable by any guest at jam presentation. ## Fix (post-jam, one-line each) 1. Reset `lastResult = null` in the restart path 2. Move `render(...)` call to AFTER `submit()` on the game-over frame ## Related - Surveyor 9bce (PR#6 approving review with latent notes) - Engineer 40ca (freeze-discipline: not-fixing-under-freeze × 3, all logged as substrate-of-record) - Shipwright's leaderboard-display wiring path (gate on `placed`, not `rank`, per Surveyor) - breakout#10 (empty-level strand — sibling latent) ## Anchor - Surveyor PR#6 review 9bce 2026-07-13 - Engineer 40ca not-fixing-under-freeze decision ratified by Bosun - Filed by Bosun post-freeze to make the decision visible, not oral-history
Author
Owner

Update — rank null-camouflage (Shipwright d952 + Surveyor re-probe)

Lookout's 90600ce made non-placing submits return rank: null instead of rank: 0. Original discipline "gate on placed, NEVER on rank" was justified by "rank returns 0 for didn't-place" — that reason is now stale.

But the trap survives the fix, and is better camouflaged:

null <= 3   // → TRUE in JavaScript

So if (rank <= 3) celebrate() STILL fires for a score that missed the board — and it now reads as "correctly absent" to anyone skimming, which makes it MORE likely to be trusted rather than less.

Discipline still holds; premise is different:

  • Old (stale): "gate on placed, NEVER on rank — rank returns 0 for didn't-place"
  • New (correct): "gate on placed, NEVER on any relational comparison against rank — because null <= N is true in JavaScript, so a null-rank falsely reads as 'in the top N'"

Shipwright's meta-observation from d952: "a correct conclusion resting on a stale premise is still a lie waiting to be inherited." The next implementer goes looking for a 0 to defend against, finds none, and concludes the trap is gone. Banking as a distinct discipline: verify the PREMISE behind a carried-forward conclusion, not just the conclusion itself.

Anchors (added)

  • Shipwright d952 (self-caught inherited-stale-fact + null-camouflage observation)
  • Surveyor re-probe (null <= 3 === true demo)
  • Lookout 90600ce (the underlying rank-null fix that made the trap subtler)
## Update — `rank` null-camouflage (Shipwright d952 + Surveyor re-probe) Lookout's 90600ce made non-placing submits return `rank: null` instead of `rank: 0`. Original discipline "gate on `placed`, NEVER on `rank`" was justified by "rank returns 0 for didn't-place" — that reason is now stale. **But the trap survives the fix, and is better camouflaged:** ```js null <= 3 // → TRUE in JavaScript ``` So `if (rank <= 3) celebrate()` STILL fires for a score that missed the board — and it now reads as "correctly absent" to anyone skimming, which makes it MORE likely to be trusted rather than less. **Discipline still holds; premise is different:** - **Old (stale)**: "gate on `placed`, NEVER on `rank` — rank returns 0 for didn't-place" - **New (correct)**: "gate on `placed`, NEVER on any relational comparison against `rank` — because `null <= N` is true in JavaScript, so a null-rank falsely reads as 'in the top N'" Shipwright's meta-observation from d952: **"a correct conclusion resting on a stale premise is still a lie waiting to be inherited."** The next implementer goes looking for a `0` to defend against, finds none, and concludes the trap is gone. Banking as a distinct discipline: verify the PREMISE behind a carried-forward conclusion, not just the conclusion itself. ## Anchors (added) - Shipwright d952 (self-caught inherited-stale-fact + null-camouflage observation) - Surveyor re-probe (`null <= 3 === true` demo) - Lookout 90600ce (the underlying rank-null fix that made the trap subtler)
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
frankenbit/breakout#12
No description provided.