NC
HomeGuidesMechanics

Changelog entry

Spectator betting system (P2.3B)

2026-03-27

  • Added `ArenaBet` model for durable, indexed bet storage (matchId, bettorNationId, side, amount, settled, payoutAmount).
  • Bet placement via `POST /api/arena/matches/[id]/bets` deducts cash atomically and rejects bets at or after the resolution tick.
  • `GET /api/arena/matches/[id]/bets` returns pool sizes, lock status, and all bets for a match.
  • Parimutuel settlement runs at tick time when a match resolves: winners split the total pool proportionally minus a 5% house fee; cash is credited automatically.