Standout Builder Studio · planning Index / Flow / 02 · Mechanic Setup draft Updated 12 Jun 2026

Proposal 02 · Mechanic Setup

This proposal covers pipeline step 3 — Configure mechanics. Today the mechanic configuration form in builder-editor.tsx is a single flat grouping with no mechanic-specific panels, no variant diff against the base game, and no inline guidance about how a field change affects RTP or volatility. This stub captures the problem, sketches one wireframe, and lists the open questions that must be resolved before a full proposal can be written.

1 Choose build path 2 Define the game package 3 Configure mechanics 4 Attach assets & theme 5 Run validation 6 Generate playable sandbox 7 Iterate 8 Promote toward handoff

Draft stub — structure and problem statement only.
Copy the full-depth anatomy of Proposal 01 / Proposal 04 when writing this proposal.

User problem

Config editing exists today in apps/web/src/views/builder-editor.tsx, which renders a form generated from a template's fields array grouped by field.group. For Crash the groups are Betting, Math & RTP, and Timing; Trunk Raider adds a fourth group, Bonuses. However the form presents all groups as one flat scroll — there are no mechanic-specific panels that collapse irrelevant sections or surface the most impactful controls first.

When a builder is working on a variant, none of the fields show which values were inherited from the base game and which have been overridden. The only diff signal is that diffFromDefaults (in builder-editor.tsx) silently excludes unchanged fields from the saved GameSpec — it is invisible to the builder. Furthermore, range-type fields such as winMultiplier {min, max} on Trunk Raider have no guidance about how the pair of values drives expected value; adjusting one end without understanding the relationship can produce an unintended RTP shift with no warning.


Proposed UI

The config editor becomes a set of collapsible mechanic-specific panels — one per field group — with a persistent "changed vs base" rail on the right that lists every field that diverges from the base game's defaults. A Math-impact note appears inline beneath any field whose change is detected as affecting RTP or volatility.

Mechanic Setup — grouped panels with diff rail (Trunk Raider variant) CONCEPT · proposed
Configure mechanics · Trunk Raider variant Base: Trunk Raider template · RTP 96.0%
Betting
Minimum bet
$0.25
Maximum bet
$1,000
Math & RTP 1 change
RTP
96.0%
Base win multiplier
min 0.1 / max 6.5
Math impact: max raised — EV shift +0.8%
Bonuses
Silent Pick threshold · Informant threshold · Cheat Code threshold · free-round counts · pot contribution %
All at base defaults — click to expand
Timing (Crash mechanic only)
Pending duration · Tick interval · Broadcast interval
Changed vs base
winMultiplier.max
5.1 → 6.5
EV shift detected
No other changes from base
Target RTP: 96.0%
Projected RTP: 96.8% — verify in Math-Sim

State variants

State variants to be designed in the full proposal
  • fresh-from-template — all fields at base defaults; diff rail empty; no warnings.
  • variant-with-inherited-diff — one or more fields diverge from base; diff rail lists each change with old → new values; EV-shift notes appear inline.
  • invalid-config — a field value violates its declared constraint (e.g. minBet > maxBet); field highlighted in red; save CTA blocked.
  • math-impact-warning — a change to a Math & RTP or Bonuses group field causes a projected RTP shift outside the declared target tolerance; amber banner in the diff rail; Math-Sim CTA promoted.

Affected current files

File Change
apps/web/src/views/builder-editor.tsx Replace the flat grouped form with collapsible per-group panels; add a diff-rail component that compares live config values against base-game defaults; wire inline Math-impact annotations to the Math & RTP and Bonuses groups.
packages/shared/src/templates.ts Field definitions may need an impact annotation (e.g. "rtp" | "volatility" | "timing" | none) so the editor can decide which changed fields warrant a Math-Sim prompt without hard-coding field keys.

What changes in the build flow

Today, a builder moves from step 2 to a flat config form with no context about what they inherited from the base game or what their changes mean for math. After this proposal, step 3 presents grouped panels with a persistent diff rail that makes inherited vs overridden values visible at a glance, and an inline Math-impact signal that prompts a Math-Sim run before the builder advances to step 4.


Open questions

Decisions needed before implementation
  • Which fields are builder-editable vs internal-only? Several fields in templates.ts (e.g. houseEdge, minCrashPoint) directly set certified math parameters. Should external builders be permitted to change these, or are they locked and surfaced read-only? This affects whether the diff rail can show a change or only show inherited values for those fields.
  • How do range fields (winMultiplier {min, max}) render? The current form handles them as two separate number inputs (see builder-editor.tsx case 'range'). The proposal sketch shows them paired with an EV-shift note, but the calculation method (mean of min/max, full simulation, or lookup) is not decided. The implementation of inline Math-impact notes depends on this.
  • Where do Math-Sim previews appear inline? Should the Math-Sim panel open in a drawer alongside the config form (preserving context), replace the diff rail on demand, or live as a separate step-3b screen? The answer determines whether the config and Math-Sim feedback loop is a single view or a two-step transition.

What to tackle next

Once the open questions above are resolved, the mechanic-setup form can be specced in full. The next stub in this reading order is Proposal 03 · Package Checklist, which covers the manifest, assets, copy, and jurisdiction state that must be assembled alongside (and after) mechanic configuration.