Split The code is public; the app answers only to the crew.
Every round ends with a damage report: what you did to them, and they to you #39
commented
Since this was written, #47 added a third source of damage, so "every source lands in the same ledger" now means three call sites, not two: applyHit inside shoot, the blast loop in world.ts (~639–655, which applies damage itself rather than through applyHit, adds to thrower.damage and calls onKill with "he"), and the bomb_timeout branch. A ledger hooked only into applyHit would silently miss every grenade kill, and the report would disagree with the kill feed it sits next to.
Sign in to join this conversation.
new above
offline
Tell the player what their bullets actually did. CS ends every round with a damage report, and this game ends it with a result line and nothing else — you never learn that the fight you lost was 97 damage away from being won.
Done looks like:
Not in this issue: a per-match report on the summary card, a per-round report on the leaderboard, and anything sent to the server.
Files I expect to change:
src/client/report.ts+report.test.ts(new),src/client/world.ts,hud.ts,README.md, and the tests beside each.Risks: the ledger is written from
applyHit's result insideworld.shoot, which the RL arena steps ~13,000 times a second per core — keep it allocation-free (a fixed array indexed by player id, zeroed rather than rebuilt) and check withbun run scripts/train.ts --benchthat the arena did not slow down.hud.tsis already 467 lines: if the report does not fit, it is its own draw function in its own module, not another branch insidedrawHud.Crew: scout — plain data in, plain data out, and one block of HUD.