kaintuck: headless engine, shared-economy server, and actionable rumor banter

kaintuck: headless engine, shared-economy server, and actionable rumor banter

#49 in Riparion/riparion-retro — merged 2026-06-14

Extracts kaintuck's game logic into a headless kaintuck-engine crate that the existing Dioxus UI drives unchanged and that can also run autonomously, then builds a shared-market economy on top — bots and humans trading in one market via an optional native server — and finally turns crew banter into a real, decision-relevant trading mechanic.

What's here

retro-core + headless engine. Pure rng/format/hash extracted into retro-core; the engine is UI-free and host-testable, wasm-clean, with the golden-trace oracle preserved throughout.

Shared-economy server (opt-in, native-only). axum + WebSocket single-owner actor; independent journeys, one shared order-book market. The wasm client joins via a riparion-ws-base meta tag — absent it, the game is byte-for-byte the offline single-player experience. Includes a sim/CLI balance harness, just server/just play/just smoke, and tracing.

Trader gossip → actionable. Bots are named and persona'd; their notable trades surface in the player's crew banter, now tagged with a price tier (premium/fair/glut vs baseline) so tips carry signal ("bid up there" / "glutted, going cheap").

Dockside rumors (single-player, deterministic, offline). At each landing the crew hears advance word about the next town's prices from a named source with a fixed reliability — sometimes true, sometimes wind; you learn who to trust. The next town's prices are pre-rolled (tagged with their town) the moment you arrive at the current one, so a tip's truth is fixed before you load cargo; the payoff resolves on arrival from the prices you actually face. Rich prose is an LLM-authored corpus baked into kaintuck.ron, selected RNG-free; regenerate the text (not the tuning) with just gen-rumors.

Dock "wharf factor" line gained a downstream gradient hint (RNG-free rank-mean) and a hold-aware sell prompt.

Determinism / golden trace

All flavor selection is RNG-free; the rumor mechanic's pre-roll + draws are a deliberate behavior change, so the golden trace was re-pinned with documented reasoning (win/loss split stays healthy; single-player uses random seeds, so only the test fixture moves).

Verification

  • cargo test --workspace green (kaintuck-engine 80 tests incl. the golden trace; server WS/market tests; all other games).
  • cargo check --workspace clean; release dx build for games/kaintuck succeeds.
  • Live: server + browser confirmed gossip tiers flow end-to-end; offline confirmed rumors render and the game is unaffected with no server.
  • Two /code-review passes on the engine/server/gossip; a third high-effort pass on the banter+rumor work with all 10 findings fixed.

Version bumps: new crates retro-core/kaintuck-engine (0.1.1)/kaintuck-server; retro-kit 0.1.9, trail-kit 0.1.13, kaintuck 0.1.23.

🤖 Generated with Claude Code

Last updated 2026-06-15