Formal Specification
Syrian Peg-Top — Formal Specification
Syria · top-spinning · Confidence: medium
← Back to game pageImplementation Suitability
Suitability: adaptation-requiredFidelity: probabilistic-proxyGap-fills: 1
# Al-Dawwama — AI-optimized specification
## General idea
A continuous-space rotational combat game where agents launch spinning tops into a 2D circular ring. Agents balance launch velocity, launch angle, and spin duration against the objective of colliding with and ejecting an opponent's top from the arena while maintaining sufficient angular momentum to stay upright.
## Formal model
- **Abstraction taken:** Physical top modeled by position , translational velocity , and angular speed . Collision between tops resolves momentum exchange and angular friction loss.
- **Player/agent count:** 2 agents (duel mode) or agents (battle royale).
- **Turn model:** Simultaneous launch phase per round, followed by continuous physics resolution until all tops stop or exit arena.
## Formal rules
R1. Setup: Arena is a 2D disk of radius centered at . Match played over rounds. Scores .
R2. Launch Action: Each agent chooses launch parameters .
- Initial spin .
- If launch fails (), top fails to spin and is eliminated immediately for the round.
R3. State Propagation:
- Positions update: .
- Spin decays: .
R4. Collision Resolution:
- When , an elastic collision occurs:
- Velocities update according to standard 2D collision equations with coefficient of restitution .
- Both tops incur angular momentum penalty: .
R5. Arena Ejection & Fall:
- If , top is ejected from the arena.
- If , top falls over ("dies").
R6. Round Scoring:
- If top remains spinning inside the arena while top is ejected or dead, agent scores 1 point.
- If both tops survive until time limit, the top with the higher remaining scores 1 point.
R7. Win condition: The first agent to accumulate 3 round points wins the match.
## Edge cases
- **Tie at the end condition:** [gap-fill] If both tops die simultaneously or finish with identical within tolerance , the round is scored as a draw (0 points awarded to both) and replayed.
- **A player with no legal move:** Not applicable; launch vector can always be selected.
- **Repetition / cycles:** Spin strictly decays monotonically (), guaranteeing every round terminates in finite time.
- **Simultaneous claims on the same resource or position:** Physics engine integrates collision at continuous contact point.
- **Player elimination mid-round; turn order repair:** In -player matches, dead/ejected tops are removed from active physics loop.
- **Resource exhaustion:** Tops are durable; launch energy resets each round.
- **Termination guarantee:** Guaranteed by exponential angular velocity decay .
## State representation
- Persistent state: `scores: [int, int]`, `round_number: int`.
- Ephemeral state (per round):
- `positions`: array of shape `(N, 2)`.
- `velocities`: array of shape `(N, 2)`.
- `spins`: array of shape `(N,)`.
- `active`: array of booleans.
- Observable information: Fully observable 2D state during round execution.
## Action space
- `launch_top(aim_angle, aim_distance, power, spin_torque)`: Continuous parameter vector .
## Playability notes
- Single-player-vs-AI: Natural; AI calculates target intercept trajectories to maximize ejection momentum against opponent tops.
- Group games (n>4): Extends cleanly to tops colliding in a larger circular ring.
- Physical-skill games: String winding tension and snapping release modeled via initial angular velocity variance.
- What is lost in the adaptation: Wood scent, rhythmic buzzing sound of high-speed rotation, and physical top-nicking scars.
## Implementation hints
- Implement a 2D Euler integrator with simple contact collision circles.
- Suggested first milestone: Implement spinning duration decay loop with stationary target top collision before optimizing multi-agent dynamic launches.
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
Syrian Peg-Top (Syria). (n.d.). Games of Countries. https://gamesofcountries.com/games/sy-syria/al-dawwama
@misc{gamesofcountries-sy-syria-al-dawwama,
title = {Syrian Peg-Top (Syria)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/sy-syria/al-dawwama}
}