Skip to main content
Formal Specification

Seven Stones — Formal Specification

Egypt · dexterity-throw · Confidence: medium

← Back to game page

Implementation Suitability

Suitability: engine-readyFidelity: probabilistic-proxyGap-fills: 2
# Sab'a Balatat — AI-optimized specification ## General idea A two-team asymmetrical tactical action game. Attackers attempt to topple a central 7-stone stack and then rebuild it, while Defenders retrieve the ball and throw it to eliminate Attackers before the stack is completed. ## Formal model - **Abstraction taken:** Field is modeled as a 2D discrete grid [−10,10]×[−10,10] with stack at (0,0). Ball trajectory and tagging are modeled as discrete ray-cast projectile checks. - **Player/agent count:** 2 teams of M agents each (reduced 2-agent form: 1 Attacker vs 1 Defender). - **Turn model:** Phase 1: Sequential stone-strike attempt. Phase 2: Simultaneous discrete real-time ticks. ## Formal rules R1. Setup: Stack has height H=7 stones at (0,0). R2. Phase 1 (Knockdown): Attacker throws ball from (0,−8) at stack. - Strike probability Ptopple=0.75+0.05×skill. - If toppled, H becomes 0; Phase 2 begins immediately with ball landing at (0,5). - If missed 3 times, teams switch roles. R3. Phase 2 Movement & Actions (simultaneous ticks): - All agents move ≤1 grid unit per tick. - Ball carrier may: `MOVE`, `PASS(target_teammate)`, or `THROW_TAG(target_attacker)`. - An Attacker at (0,0) with no defender within 2 units may execute `BUILD_STONE()`: increments H by 1. R4. Elimination Resolution: - When Defender executes `THROW_TAG(A)`: - Line-of-sight is checked; hit probability Phit=max⁡(0.2,1.0−0.1×dist+0.05×skill). - On hit, Attacker A is `ELIMINATED` from the round; ball drops at A's position. - On miss, ball travels to boundary and drops. R5. Win Conditions: - Attacker Win: If H==7, Attackers win the round (+1 point). - Defender Win: If all Attackers are `ELIMINATED`, Defenders win the round (+1 point). R6. [gap-fill] Phase 2 Time Limit: Maximum 100 ticks per round. If tick 100 is reached with H<7 and surviving attackers, Defenders win the round. R7. [gap-fill] Match Termination: Match ends after 5 rounds. Team with highest score wins. ## Edge cases - Tie at the end condition: If match score is tied at 5 rounds, 1 sudden-death round is played. - A player with no legal move: In open grid, `WAIT` or directional movement is always legal. - Repetition / cycles: Bounded by the 100-tick hard round limit (R6). - Simultaneous claims on the same resource or position: Defender tagging has priority over `BUILD_STONE()` if executed on the same tick. - Player elimination mid-round; turn order repair: Eliminated agents become inactive; active agents continue simultaneous execution. - Resource exhaustion (pieces, tokens, space, time): Ticks strictly expire at 100; stones capped at 7. - Termination guarantee: Guaranteed by the 100-tick cutoff and monotonic elimination / stack count updates. ## State representation - Persistent state: `team_scores`: `{ATTACKERS: int, DEFENDERS: int}`, `round_num: int`. - Per-round state: - `stack_height`: integer in `0..7`. - `ball_state`: `{pos: (x, y), holder: AgentID | None}`. - `agent_states`: map of `agent_id` to `{pos: (x, y), status: ACTIVE | ELIMINATED}`. - `tick_counter`: integer in `0..100`. - Observable information: Fully observable by all agents. ## Action space - Attacker: `move(dx, dy)`, `build_stone()`, `wait()`. - Defender: `move(dx, dy)`, `throw_tag(target_id)`, `pass_ball(teammate_id)`, `pick_up_ball()`. ## Playability notes - Single-player-vs-AI: Natural; human player acts as Attacker builder or Defender thrower against AI bots. - Group games (n>4): Standard 3v3 team dynamics create rich passing and flanking strategies. - Physical-skill games: Physical dodgeball aiming and rapid stone balancing are abstracted to distance-decay probabilities and build timers. - What is lost in adaptation: The physical sting/impact of the ball and improvised terrain dodging. ## Implementation hints Standard 2D grid multi-agent simulator with discrete projectile mechanics. First milestone: implement stone building at (0,0) and simple Defender pursuit-and-throw logic before adding team passing.

Download as JSON

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

Download JSON
Cite this page

Seven Stones (Egypt). (n.d.). Games of Countries. https://gamesofcountries.com/games/eg-egypt/sabee-balatat

@misc{gamesofcountries-eg-egypt-sabee-balatat,
  title = {Seven Stones (Egypt)},
  year = {n.d.},
  publisher = {Games of Countries},
  url = {https://gamesofcountries.com/games/eg-egypt/sabee-balatat}
}