Skip to main content
Formal Specification

Glass Marbles — Formal Specification

Bulgaria · dexterity-small · Confidence: medium

← Back to game page

Implementation Suitability

Suitability: engine-readyFidelity: probabilistic-proxyGap-fills: 4
# Limki — AI-optimized specification ## General idea A turn-based spatial staking and projectile collision game. Players contribute spherical glass tokens (*limki*) to a bounded circular target zone on a 2D plane and execute precision impulse shots with a designated heavy shooter token (*biyach*). Dislodged tokens are captured, granting immediate turn extensions and positional continuity. ## Formal model - **Abstraction taken:** The 2D physical roll, spin, and collision dynamics of glass spheres are modeled as elastic 2D momentum transfers with friction-based velocity decay, parameterized by release angle, flick power, and stochastic aim deviation. - **Player/agent count:** K players (K∈[2,6]). - **Turn model:** Sequential turn rotation with conditional continuation on successful capture. ## Formal rules R1. Setup: - Target circle centered at (0,Ytarget) with radius Rring=0.40 m (Ytarget=3.0 m). - Each player stakes S marbles (S≥1). Total pot M=K×S marbles are placed inside the ring at discrete coordinates 𝐩m1..𝐩mM. - Each player possesses one distinct shooter marble 𝐬i with mass mshooter=1.8⋅mtarget. R2. Turn Order: - Players shoot toward baseline y=0; ascending distance error determines turn sequence [P1,…,PK]. R3. Shooting Action: - Active player submits impulse vector 𝐉=(θ,F) from current shooter coordinate 𝐬i (initial shot from baseline y=0). - [gap-fill] Actual release vector: 𝐉actual=𝐉+𝒩(0,Σflick), where covariance matrix Σ is scaled inversely by player AimPrecisioni. R4. Collision Dynamics and Extraction: - Trajectory integrates velocity decay d𝐯dt=−μfrictiong𝐯ˆ. - If ||𝐬i−𝐩mj||≤2rmarble, elastic collision occurs: impulse is transferred to target marble mj. - Extraction check: If ||𝐩mj−(0,Ytarget)||>Rring, target marble mj is extracted, removed from the ring, and credited to the active player's bank (Bi←Bi+1). R5. Turn Continuation and Opponent Elimination: - If count of marbles extracted on current shot E≥1: - Active player collects extracted marbles. - Active player retains turn and shoots next shot from current resting position 𝐬i. - If an opponent shooter 𝐬k is struck by 𝐬i: - Opponent Pk must transfer 1 marble from bank Bk to active player Bi [gap-fill]. - If E==0 (no marbles extracted): Turn ends; shooter 𝐬i remains resting at its stopping position on the board; turn passes to next player (current_player+1)(modK). R6. [gap-fill] Turn Cap: An active player may execute at most 5 consecutive shots in a single turn to avoid table clearing runouts. R7. Victory Condition: - Game terminates when all M target marbles have been extracted from the ring (Mremaining==0). - The player with the highest total bank count Bi wins the match. R8. [gap-fill] Tiebreaker: If bank counts are equal, tied players execute one sudden-death shot at a single center marble; closest landing wins. ## Edge cases - Tie at the end condition: Fully resolved by R8 sudden-death target shot. - A player with no legal move: Not applicable — shooting action with aim vector is always legal on agent's turn. - Repetition / cycles: Bounded: Target marbles M strictly decrement toward 0; each non-scoring shot forces a mandatory turn pass. - Simultaneous claims on the same resource or position: Turns are strictly sequential; marbles are distinct persistent entities indexed in memory. - Player elimination mid-round; turn order repair: If a player disconnects, their resting shooter marble is removed from the board; banked scores remain static; turn sequence skips the disconnected index. - Resource exhaustion: Target marble count decrements to exactly 0, triggering game termination R7. - Termination guarantee: Monotonic reduction of target marbles M→0 combined with finite turn limits. ## State representation - Persistent state: Player bank counts [B1,…,BK], player precision attributes, active player index c∈[1,K]. - Per-turn ephemeral state: Array of remaining target marble coordinates [(x1,y1),…,(xm,ym)], resting shooter coordinates [𝐬1,…,𝐬K], consecutive hit counter. - Observable information: Fully observable — all token coordinates and player bank counts are public. ## Action space - `shoot_marble(angle, force)`: Precondition: Caller is active player, pot has remaining target marbles (m>0). ## Playability notes - Single-player-vs-AI: Natural — Human player lines up shot angles and power against AI agents equipped with geometric collision optimization heuristics. - Group games (n>4): Natively supports 2 to 6 players in turn rotation without modification. - Physical-skill games: Fine-motor knuckle placement and thumb flick dynamics are parameterized via 2D vector physics and Gaussian noise. - What is lost: The visual aesthetics of swirling cat's-eye glass patterns and the physical sound of glass marbles clinking are replaced by coordinate arrays. ## Implementation hints Standard 2D rigid-body disc collision model. Branching factor is continuous but discretizes cleanly into ~16 aiming sectors and 5 power levels. Suggested first milestone: implement the 2D circle boundary containment and impulse transfer physics for 2 players with 4 target marbles.

Download as JSON

Download the full game corpus entry for this game as structured JSON.

Download JSON
Cite this page

Glass Marbles (Bulgaria). (n.d.). Games of Countries. https://gamesofcountries.com/games/bg-bulgaria/limki

@misc{gamesofcountries-bg-bulgaria-limki,
  title = {Glass Marbles (Bulgaria)},
  year = {n.d.},
  publisher = {Games of Countries},
  url = {https://gamesofcountries.com/games/bg-bulgaria/limki}
}