88a42ae9e2b8fbaeb8986a2bb33322245dbd537d
2
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
88a42ae9e2 |
v0.7.9.7 — a device that said it was available all day after it was gone
The last item off 0.7.9.6's sweep, parked there as the one genuine maybe. It had a second half worth more than the first. #101 — Telegraph (+4), Telephone (+8) and Radio (+12) are "once a day, when dispatching facing trains, add +N to the other train's number". `enhancementText(key)` takes only the KEY, so the tooltip could not vary with anything: a spent Radio read "Once a day, add +12..." for the rest of the Day, advertising a bonus that was not there. That is `trainRules` before #100, in another corner of the same view. THE HALF THAT ACTUALLY SURPRISES. `spendDispatchBonus` reads `areaOf(s, s.clock.superintendent)` — the SUPERINTENDENT's own devices, not the train owner's — and the Fedora moves every STAGES_PER_SHIFT (3) Stages, four times a Day. So a player's Radio does nothing at all for three-quarters of the Day, and is spent automatically, without its owner being asked, during the quarter it is theirs. Neither half was anywhere on the board. The card now reads as one of three states — available and dispatching, unspent but idle while somebody else holds the Fedora, or spent until the next Day — and names the shift length, because "not now" without "for how long" is half an answer. A spent device is struck through on the board. Shown on EVERY district, not only the viewer's (Jesse's call): it is public, and a rival's spent Radio is what you want to know before forcing a meet. What counts as a device is `enhancementRule(key)?.dispatchBonus` rather than three keys written out in the view — the ladder lives in ENHANCEMENT_RULES and a fourth rung would otherwise be silently exempt. A STALE COMMENT CORRECTED, AND PINNED. `advance.ts` warned that indexing a SEAT-keyed area with the PLAYER holding the Fedora "is right only while seating is the identity map". It read as a live Employee Rotation bug and was not one: `areaOf(s, p)` IS `areaAtSeat(s, seatOf(s, p))`. A comment that sends the next reader chasing a bug that does not exist costs about what the bug would. Rewritten, and the claim is now a test — seating set to a real permutation, and the Superintendent's own district rather than the seat with the same index is the one that reads as dispatching. TWO THINGS MUTATION CAUGHT THAT PASSING DID NOT. A test asserted the ABSENCE of /spent|Fedora/ with the Fedora held, and a mutant with the `dispatchBonus` guard deleted PASSED it — the leaked text in that case says "Available today, and this district is dispatching", which contains neither word. A test that something was left alone has to compare it against what it should be, so it asserts equality with `enhancementText` now, in both Fedora states. And the replay wire format needed the field: cells pack positionally, so the flag is index 9 and reads `?? []`, the same tolerance `standingWest` uses — older recordings report no device spent, which is what they drew at the time, so every published replay is unchanged. 943 tests pass, up from 934. NOT VERIFIED AT A TABLE, like 0.7.9.6. #39 and #35 still stand. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y5boPxP6JHRYMm8adXaF5R |
||
|
|
7f4e027258 |
v0.7.9.6 — three things the engine knew and the screen did not
Found by looking rather than by being told. Gitea#21, #22, #94 and #96 were four instances of one fault in a row — the engine gains something that changes what a train may do, and nothing draws it — and every one was found by a player hitting it. So instead of waiting for the fifth, every field of GameState and its nested types was enumerated, checked for a reader in sim/view.ts, src/web/ and sim/narrate.ts, and the survivors verified BY RUNNING THE ENGINE rather than by trusting the grep. Four fields had no reader. `movedThisPhase` lives and dies inside one `advance` call and is nobody's business. The other three are below. What was ruled out matters as much: `freightWorked`, `drawnThisTurn`, `freightAgentUsed`, `switchedSince` and `movesUsed` are invisible on purpose, their effect already showing as legality or as a complement already on the Frame. A field is not a display gap merely because nothing renders it. #98 — the Crew Tray pool. §7 scarcity is called an explicit mechanic and was explicit only in the engine. The blocked panel had one tray rule, keyed off the train due out this Stage, so a player who spent a card on an Extra or ordered a second section got an EMPTY panel while their train sat behind an exhausted pool — both having been announced once in the log in a line promising a future event that nothing then confirmed. The shared table carries the pool and the queue now, so the common board gets it too, and the panel reports all three with the count beside them. #99 — a train held at the Limits vanished off the board, and this one had shipped. The Interlocking stops an inbound train on the Limit Track rather than colliding with a full Office. `arriveAtOffice` removes the tray from the Mainline node's `transits` and the Interlocking branch pushes it onto `heldAtLimits` without assigning `tray.position` — and the map draws mainline nodes from `transits` and squares from `position.at === 'grid'`, so between the two it was drawn in NEITHER. It disappeared on arrival and reappeared in the Office some Stages later. Fixed in the view: the engine is right, and `position` is left alone deliberately so nothing treats the train as standing somewhere it could be switched from. #100 — the Campaign Train's speeches change its rules, and the card said the same thing before and after. Worse, the "EXPEDITED ... costs 1 Revenue" warning prints only under `rules.expedite`, so X17 became subject to a fault whose warning the game shows to every other expedited train and never to it. `trainRules` reads `speechMade` now and borrows `isExpedited` from advance.ts rather than restating the test. #45 — the 0.7.9 dead-field audit, finished, and the answer was different for each. `overHandLimit` is WIRED: its consumer existed all along and was inferring the hand limit from the ABSENCE of `draw.end` in the menu, which is sound only while `check` keeps refusing for exactly three reasons. `viewerSeat` is DOCUMENTED, with a condition — Gitea#20's board keys districts by seat, and the note says to delete it if step 2 ships without using it. The audit had missed a third limb. `game.mustPlayCard` was assigned on every submit and read by nothing: deleted. Chasing it turned up the thing worth fixing — the §6.2 hand-limit test existed in THREE places, all agreeing, which is the state #96's disagreement started from. One `overHandLimit(state, player)` in state.ts now, and the other two ask it. `Session.overHandLimit()` is deleted rather than kept: the Frame already carries the fact, so the method was a second path to it. 934 tests pass, up from 917. The 17 new ones were written red, and each fix checked by mutation: reverting `speechMade` fails 2, dropping the held-train projection fails 4, forgetting the tray queues fails 2. The empty blocked panel is reported beside its positive control, since an empty result from a broken function proves nothing. NOT VERIFIED AT A TABLE. Engine and view work, checked by tests and by running the engine. #39 and #35 still stand. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y5boPxP6JHRYMm8adXaF5R |