Files
station-master/docs/components.md
T
Jesse.MarkowitzandClaude Opus 5 3befc420da v0.8.2 — every district opens on a Depot, and the docs are pages now
A second-digit bump for a playtest read back against the save file. Nine questions
were asked of one three-Day game; three were bugs, three were the rules working
and undocumented, three were decisions. Every save on the test server was replayed
against this build BEFORE release, which is how the cost of each rule was known
before it was chosen rather than discovered after.

EVERY DISTRICT OPENS ON A DEPOT. A Whistle Post has one A/D track and is not a
Passenger Facility, so the opening of every game was spent unable to work a
passenger and one arrival away from a collision. Two A/D tracks and passengers
from Stage 1 now; "Players start with Whistle Posts, not Depots" is the harder
game, set when the game is created. The deck follows the choice — starting on
Depots the four Depot upgrade cards are left out, because an upgrade must be to
the next tier and a Depot card at a table of Depots is a dead draw. How much
easier it is showed up as a test failure rather than an argument: the cue-coverage
pool needed widening from 24 seeded games to 60 before it held one collision.

NO SAVE WAS STRANDED BY IT, which took care. This is the one house rule that
changes how a game is DEALT rather than how it plays, so replaying a save under
the wrong opening is a different railroad from intent one — silently, with no
error. `withSavedOpening` fills it on the replay paths ONLY. Putting it in the
resolver instead made a fresh Cutthroat game deal Whistle Posts and read as
Custom, which is how the distinction was found.

THREE BUGS, ALL REPORTED FROM ONE GAME AND ALL CONFIRMED ON ITS SAVE.

An Office held TWO TRAINS ON ONE A/D TRACK. The capacity test passed with nothing
standing, the train the Interlocking had been holding at the Limits was moved into
the free slot, and the arriving train was pushed in after it without anyone asking
again whether there was room — so the collision §8.3 calls for never happened. The
held train keeps priority; the newcomer now takes the consequence it would have
met had the held train arrived first.

THE HISTORY FROZE, permanently, and the log cap was not really the cause. Each
seat's "what have I sent you" bookmark was an INDEX into an array the game trims,
so once a seat's bookmark reached the limit the slice returned nothing for the
rest of the game — at a different moment per seat, because each holds its own.
That game's log ended at exactly the cap. Lines carry a sequence number now, which
survives trimming; proven by pushing twice the cap through a simulated seat.

§8.1 ASKED THE WRONG QUESTION TWICE. "Trains may pass" returned `clear` before the
Subdivision was looked at, so a train entering a Double Track was released however
busy the rest of it was — that, not anything about Control Points, is what let
Train 8 out with no ruling. And a train standing at an Office was invisible to the
scan, so one about to re-enter the very Subdivision being entered counted for
nothing. Capacity is the test, not presence: a Depot with a track free is not in
the way; a Whistle Post with its one track taken is.

THINGS THAT HAPPENED SILENTLY NOW SAY SO — a train held against a facing one, a
train released from the Limits (a side effect of somebody else's arrival, so it
simply appeared at the Office), and the train an Interlocking is holding, whose
explanatory tooltip has existed since #99 with NO renderer ever reading the flag.

WHERE A MOVE IS REFUSED, AND WHY. `exploreMoves` decides where the rails go and the
pick-up restrictions are enforced afterwards in `check`, so a square the rails
reached and the card forbade was reachable, un-offered, and absent from the block
list with nothing said. Those squares are blocked with the rule that blocks them
now, and the reasons are got by ASKING `check` rather than re-deriving: a second
implementation of the rules is exactly the failure the block list exists to avoid.
A train may also always recover its own caboose — X13 prints "may drop but not
pick up anything", and a train needs its caboose to be made up, so one that parted
with it could never legally leave again.

RULES DECIDED IN SEPTEMBER AND APPLIED HERE. A Modifier must sit square against its
host, no diagonals. A passenger Modifier may not be played at a Whistle Post. Both
were built, measured, held back for a fortnight so a playtest could finish, and
applied now. A Second Section costs its card: `SECOND_SECTION` was declared in
content.ts and never dealt, so the action was free and the bot ordered 26
accidental ones in a measured round. The card is dealt and spent — gating on a card
the deck never holds would have deleted the mechanic rather than fixed it.

THE DOCUMENTATION IS A SET OF PAGES, not five text files served as text/plain — a
card reference is mostly tables, and as plain text a table is rows of pipes.
Markdown is still the one copy; the build renders it, and publishes the .md beside
each page. No Markdown library: this project has no runtime dependencies and one
would be a poor first. The pages add what Markdown cannot carry without drifting —
a nav across the set, a contents list built from the headings actually rendered,
an anchor on every heading, a 70-character measure, and tables that are tables.
They print as ink on paper.

The references caught up with the rules, checked rather than assumed: two
statements had gone from stale to misleading (the Quickstart told a new player to
"get a Depot down as soon as one appears"), and four rules nobody could look up
are written down — the Office tier table, §8.1 in practice, what the Circus Train
pays for, and that a Realignment can be a card with no legal target.

Adding one card to the deck reshuffles every seeded deal, which broke five
fixtures. Each was a seed meaning "a game like this" — TODO #84, exactly — so
seeds moved and pools widened rather than assertions weakening, and the clearance
fixture pins its terrain the way `enhancements.test.ts` already does. The three
published replays were re-recorded.

Closes TODO #40, #42a, #108, #109 and #110.

1046 fast tests and 35 sim tests pass.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MUizFYCMHRWhbWwXhp7WPR
2026-09-23 07:07:21 -04:00

119 lines
6.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Station Master — Components and Markers
**Version 0.8.2** · 2026-09-23
**Scope:** non-card physical components and supplies. Card-created facilities, workers, deck piles,
hand state, timetable state and other markers are documented with their cards or in the
[rules book](rules.md).
The figures below are checked against `ROLLING_STOCK_SUPPLY` and the supply constants in
`src/engine/content.ts`. They are physical inventory rather than deck tuning, which is why they are
printed here at all — per-category CARD counts are not published, because they move with play balance.
## Rolling stock
Rolling stock has a type and a load state. In the interface, coloured cars are loaded and white cars are empty. The Division Yard starts with the following supply.
| Type | Loaded | Empty | Total | Use |
| --- | ---: | ---: | ---: | --- |
| Coach | 8 | 8 | 16 | Passenger work. |
| Boxcar | 10 | 10 | 20 | Freight House outbound/inbound; Grocer’s Warehouse inbound. |
| Hopper | 8 | 8 | 16 | Mine Tipple outbound; Power Plant inbound. |
| Reefer | 5 | 5 | 10 | Packing Sheds outbound; Grocer’s Warehouse inbound. |
| Tank car | 6 | 6 | 12 | Refinery outbound; Power Plant inbound. |
| Caboose | 6 | 0 | 6 | Required or permitted at the rear of the applicable train cards. |
| **Total** | **43** | **35** | **78** | |
The engine is not rolling stock and does not count against the four-car Crew Tray limit.
## Other supplies
| Component | Count | Note |
| --- | ---: | --- |
| Crew Trays | players + 3 | Engine and tray are one combined resource; there is no "engine without a tray". |
| Office cards | 4 | Every player starts on one. The starting Office is not drawn from the deck. |
| Limits signs | 8 | "2N + spares", so relocating one is never a supply question. |
## The two yards
### Division Yard
The Division Yard is the active supply. It provides:
- loaded cars to a Freight Agent stocking a green outbound box;
- empty cars for building up trains;
- an empty coach when passengers detrain; and
- an empty matching freight car when a loaded freight car begins unloading.
When a train completes a run or is destroyed, its caboose returns to the Division Yard. When a car is taken from the Division Yard and that yard has become entirely empty, every car from the Classification Yard moves back into the Division Yard immediately.
### Classification Yard
The Classification Yard collects used rolling stock: cars displaced by boarding passengers, cars
cleared from inbound red boxes, cars removed by unjamming a facility, ordinary cars from completed
or destroyed trains, and empty cars replaced by a completed outbound freight load. It is not a
player-selectable source. It returns to service only when the Division Yard is empty.
> **This is a one-way ratchet for COACHES, and it decides games.** Boarding sends an emptied coach
> here; detraining takes a fresh empty out of the *Division* Yard. Nothing returns a coach to the
> Division Yard except the bare-yard refill — and a yard kept topped up with freight cars returning
> from industries may never run bare. Measured over one three-Day game, every coach was here by the
> middle of Day 2 and stayed. See [Rules](rules.md) §4.6.
## Crew Trays and trains
Crew Trays represent an engine and its coupled consist. The game creates **players + 3** free trays at setup. A tray is scarce: a due train without a free tray is held for that Stage, and Extras wait until one becomes free.
Within a tray, the engine can pull, push, or be between cars while switching. To depart an Office for the Mainline, it must be made up with the engine at an outer end; if it has a caboose, the caboose must be at the opposite outer end. A train may have at most four cars. A scheduled train can run under-strength but never with more than its card allows.
## Fedora
The **Fedora** is the physical marker for the Superintendent. The player with it resolves
following-train clearance decisions, takes the Yard Office and Red Flag questions, and is the player
every round round the table starts with. A Mainline collision is their fault by §10, and costs 5
Revenue. The initial holder is the first player tied for the highest Superintendent setup D12 roll.
It passes at the end of Stages 3, 6, 9 and 12 — every third Stage, at the Supervisor Shift. The
handover is **announced on screen and written into the history**: it is the one thing in the game
that changes hands on the clock rather than because somebody did something, so nobody is watching
for it. Note that the Supervisor Shift refreshes every Laborer and Porter *every* Stage
while the Fedora moves only every third.
## D12 and seeded randomness
The D12 is used by the engine for:
- the initial seating roll in a multi-player engine game;
- the initial Superintendent roll;
- a timetabled train’s timetable slot; and
- all shuffled deck order and automatic setup selection through the same seeded random stream.
The rules engine uses a deterministic 32-bit seeded random generator. The same numeric seed, player configuration, house rules, and accepted intent sequence reconstruct the same game. A seed by itself is not enough when house rules differ.
## The Office, tier by tier
Every player has one Office card. It is a property of the district rather than a card that is
swapped, so an upgrade raises the numbers in place and leaves anything built beside it alone.
| Office | A/D tracks | Porters | Passengers out / in | Control Point |
| --- | ---: | ---: | --- | :---: |
| Whistle Post | 1 | 0 | 0 / 0 | — |
| Depot | 2 | 1 | 1 / 1 | yes |
| Station | 3 | 2 | 2 / 2 | yes |
| Terminal | 4 | 3 | 3 / 3 | yes |
**A/D tracks are what decide whether an arrival is a collision.** A train pulling in to an Office
with every track occupied collides (§8.3) unless an **Interlocking** holds it out on the Limit
Track. A train held that way takes the first track to free, ahead of anything arriving after it.
**A Whistle Post is not a Passenger Facility.** It has no Porters and no passenger boxes, so nobody
boards or gets off there however well the district is built, and the passenger Modifiers — Waiting
Area, Restaurant, Hotel — cannot be played at one.
**A Control Point divides the Mainline into Subdivisions**, which is what §8.1 reasons about. A
table of Whistle Posts is one Subdivision from end to end; every upgrade splits one in two and buys
the Division capacity.
**Games open on a Depot** unless the table turns on "Players start with Whistle Posts, not Depots"
when the game is created. See the Home deck reference.