Record the engine/UI seam as an architectural decision #34
Labels
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rosa/casino#34
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent
#27
What to build
An architectural decision record for the shape three games now share: a game
separates a value-returning engine, which owns the rules and answers in payouts,
from a UI, which owns the terminal and the bankroll and holds no rules of its
own. The engine's alternate constructor — a fixed wheel, a scripted sequence of
dice — is the determinism seam that makes the rules testable.
Blackjack established it, roulette followed it, craps makes three. Poker is next
in line and currently has no engine to split at all, so the next person to reach
for this should find a decision rather than three examples to infer from.
Worth capturing: why the randomness lives inside the engine rather than being
supplied by the caller, why the engine never touches the bankroll, and how this
sits with the existing decision to take the wager up front — the engine can
report what a position returns precisely because the money already left.
Acceptance criteria
record's format and numbering
restating it
there first as justification
Blocked by