Formal Specification
Hong Kong Glass Marbles (彈波子 / Marbles Knockout) — Formal Specification
Hong Kong · dexterity-small · Confidence: low
← Back to game pageImplementation Suitability
Suitability: adaptation-requiredFidelity: probabilistic-proxyGap-fills: 4
# Daa Bo Zi — AI-optimized specification
## General idea
A turn-based precision projectile physics and token capture game based on Hong Kong street glass marbles (*Daa Bo Zi*). Players shoot their master shooter marble into a designated target circle to knock opponent stake marbles outside the boundary line, balancing aggressive ejection power against the positional risk of leaving their master marble vulnerable or out-of-bounds.
## Formal model
- **Abstraction taken:** Manual thumb-flick mechanics are modeled via a 2D vector shooting action (angle , power ) perturbed by a parameterized Gaussian execution error model. Collisions between spherical marbles on flat concrete are resolved using 2D rigid-body elastic collision dynamics with friction deceleration.
- **Player/agent count:** 2 to 6 players taking sequential turns in fixed cyclic order.
- **Turn model:** Sequential turns. An active player shoots once per turn, with conditional bonus shots awarded upon successful in-ring knockout.
## Formal rules
R1. **Setup & Pot:** A circular arena of radius centered at is marked on a 2D plane. Each of the players contributes stake marbles placed inside the inner ring zone (). Total stake pool marbles.
R2. **Shooting Stance:** On their first turn, players shoot their master marble from the boundary baseline . On subsequent turns, a player shoots from the exact resting position of their master marble from the previous round (or from the baseline if their marble exited the arena).
R3. **Shooting Action:** The active player selects an aim angle and impulse magnitude . The engine simulates the trajectory and momentum transfer of all affected marbles until all bodies come to rest.
R4. **Capture Condition:** Any stake marble whose final resting position satisfies is ejected from the ring and immediately captured by the shooter ( point / marble secured).
R5. **Bonus Shot:** If a shot ejects at least one stake marble outside AND the shooter's master marble comes to rest inside the ring (), the player immediately earns 1 additional bonus shot.
R6. **Victory:** The game terminates when all stake marbles have been knocked out of the ring. The player with the highest count of captured marbles wins the match.
R7. [gap-fill] Ring Knockout geometry: Fixed arena radius , master marble radius , coefficient of restitution , kinetic rolling friction .
R8. [gap-fill] Stochastic execution noise: The actual applied shot angle is with , and actual power is with , where and .
R9. [gap-fill] Consecutive bonus cap: A player may execute at most 3 consecutive bonus shots in a single turn before turn passing is enforced.
R10. [gap-fill] Loop-breaking turn cap: If stake marbles remain after 50 rounds ( turns), the match immediately ends; winner is decided by current captured marble tally, with ties broken by closest distance of master marble to origin .
## Edge cases
- **Tie at the end condition:** If players capture an equal number of marbles, tie is broken by R10 (closest master marble to circle center ).
- **A player with no legal move:** A player with an active master marble always has a legal shot action .
- **Repetition / cycles:** Players repeatedly missing shots are bounded by the 50-round cap in R10.
- **Simultaneous claims on the same resource or position:** Shots are strictly sequential; all marble physics resolve to full rest before the next player acts.
- **Player elimination mid-round:** Not applicable; all players remain active until the stake pool is exhausted or round limit is reached.
- **Resource exhaustion:** Captured stake marbles are removed permanently from the board. When board stock , game terminates deterministically.
- **Termination guarantee:** Guaranteed by finite board stake count (monotonically non-increasing) and R10's 50-round termination hard cap.
## State representation
- **Persistent state:** `arena_radius: float = 1.0`, `stake_count_initial: int`.
- **Per-player state:**
- `master_pos: Tuple[float, float]`
- `captured_marbles: int`
- `is_in_bounds: bool`
- **Per-turn ephemeral state:**
- `active_player: int`
- `stake_positions: List[Tuple[float, float]]`
- `consecutive_bonus_count: int`
- `current_round: int`
- **Observable information:** Fully observable 2D state space. All coordinates, velocities, and score counts are public.
## Action space
- `shoot(theta, power)`: Parameters: `theta in [0, 2*pi)`, `power in (0.0, 1.0]`. Preconditions: agent is active player, `power > 0`. Triggers physics rollout.
## Playability notes
- **Single-player-vs-AI:** Highly playable. AI agents use physics rollout prediction (sampling with Monte Carlo trajectory evaluations) to target clusters of stake marbles or execute tactical snipes.
- **Group games (n>4):** Supports 2 to 6 players natively in standard round-robin rotation.
- **Physical-skill games:** Thumb-flick biomechanics and surface irregularities are abstracted into 2D Newtonian collision equations with Gaussian angular/power perturbations.
- **What is lost in the adaptation:** Physical tactile friction of marble glass, knuckle pain on rough asphalt, and manual spinning spin-tricks (*English/backspin*) are simplified into linear friction rollouts.
## Implementation hints
- Implement a 2D disc collision physics resolver (or use a lightweight engine like Box2D / custom Verlet integrator).
- State is continuous (coordinates ), but turn structure is strictly discrete.
- Branching factor: Continuous action space can be discretized into a polar grid of 36 angles 10 power levels (360 discrete actions) for Q-learning or MCTS.
- First milestone: Headless 2-player simulation with 4 stake marbles in a 1m circle verifying collision conservation of momentum and capture detection.
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
Hong Kong Glass Marbles (彈波子 / Marbles Knockout) (Hong Kong). (n.d.). Games of Countries. https://gamesofcountries.com/games/hk-hong-kong/daa-bo-zi
@misc{gamesofcountries-hk-hong-kong-daa-bo-zi,
title = {Hong Kong Glass Marbles (彈波子 / Marbles Knockout) (Hong Kong)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/hk-hong-kong/daa-bo-zi}
}