Formal Specification
Two Fires (Polish Dodgeball with Captains) — Formal Specification
Poland · ball-team · Confidence: low
← Back to game pageImplementation Suitability
Suitability: adaptation-requiredFidelity: discretizedGap-fills: 1
# Dwa ognie — AI-optimized specification
## General idea
A tactical two-team court elimination game with an active rear pincer mechanic. Each team controls a main court zone while their captain (*matka*) commands the baseline behind the enemy, allowing coordinated crossfire attacks. Defending agents must balance spatial spacing to dodge incoming throws while maintaining catching readiness.
## Formal model
- **Abstraction taken:** The 18×9 m court is discretized into a 6×3 grid per team half (Zones and ), plus one rear baseline zone for each captain ( behind Field B, behind Field A). Continuous ball throwing is discretized into turn-by-turn target projectile actions with stochastic dodge/catch resolutions.
- **Player/agent count:** 2 teams of 6 agents (Team A, Team B). 1 *matka* + 5 fielders per team.
- **Turn model:** Tick-based alternating ball possession turns. The team holding the ball chooses 1 throw action; defending agents execute simultaneous positional micro-adjustments on the grid.
## Formal rules
R1. **Setup:** Team A fielders start in Field A; Team B fielders in Field B. Captain starts in (behind Field B); starts in (behind Field A). Team A starts with ball possession.
R2. **Action selection:** The active ball-carrier may execute one of two actions:
- `pass(target_teammate)`: Relay the ball across fields to a teammate (including the *matka* in the rear zone). Pass succeeds with probability .
- `throw_strike(target_opponent_id)`: Attack an opponent agent standing on the opposite court.
R3. **Strike resolution:** When `throw_strike(target)` is executed:
- Target agent can choose `dodge()` (improving evasion probability based on agility and distance from thrower) or `attempt_catch()` (attempting an airborne catch with probability ).
- If dodged successfully or missed, ball lands on ground and is retrieved by the nearest defending agent or rear *matka*.
- If hit and not caught, the target is eliminated (*zbity*).
- If caught cleanly, the thrower's attack fails and the defender gains immediate ball possession.
R4. **Elimination transition:** An eliminated fielder moves immediately to their team's rear baseline zone and joins their *matka*, gaining the ability to receive passes and throw attacks from the rear.
R5. **Mother's entry:** When all 5 fielders of a team are eliminated, the *matka* transitions from the rear baseline into the main court field with lives.
R6. **Victory condition:** When a team's *matka* suffers 3 successful strikes (), that team is eliminated and the opposing team wins immediately.
R7. [gap-fill] **Turn possession timer:** A team cannot make more than 3 consecutive passes between the main field and baseline without executing an attack throw (`throw_strike`).
## Edge cases
- **Tie at the end condition:** Not applicable; elimination is sequential and strictly decrements life counts until one *matka* reaches 0 lives.
- **A player with no legal move:** Any agent holding the ball has a legal `pass()` or `throw_strike()` action.
- **Repetition / cycles:** Bounded by R7 (pass limit rule) and the strict non-zero probability of strike elimination on every attack throw ().
- **Simultaneous claims on the same resource or position:** Discretized grid allows at most 1 agent per cell; conflicts in movement resolve by agent ID priority.
- **Player elimination mid-round; turn order repair:** Eliminated players immediately relocate to the rear zone and remain active pass/attack options; turn order is possession-driven rather than fixed player order.
- **Resource exhaustion:** 1 ball in constant play; no consumable items.
- **Termination guarantee:** The game state is a finite absorbing Markov chain where states with fewer active players and *matka* lives strictly decrease with positive probability each cycle until reaching the absorbing win state.
## State representation
- **Persistent state:** `matka_lives` (Map[TeamId, Int: 0..3]), `possession_team` (TeamId), `ball_carrier_id` (AgentId), `consecutive_passes` (0..3).
- **Per-player state:** `agent_location` (Map[AgentId, ZoneCoord]), `agent_status` (ActiveField / RearBaseline / Eliminated).
- **Observable information:** Fully observable state; all agent positions, ball location, and life totals are public.
## Action space
- `pass(recipient_id: AgentId)`: Pass ball to a teammate.
- `throw_strike(target_id: AgentId)`: Ball attack on an opposing player.
- `move(target_cell: Coord)`: Reposition to an adjacent grid cell on the home court.
- `defend_choice(choice: Enum[DODGE, CATCH])`: Defensive reaction when targeted by a strike.
## Playability notes
- **Single-player-vs-AI:** Natural — human controls the ball-carrier decisions and defensive dodging for their squad against an AI team.
- **Group games (n>4):** Solved cleanly via 2 squad-level coordinating agents.
- **Physical-skill games:** Modeled with 3 agent attributes: `throw_power`, `dodge_agility`, `catch_skill`.
- **What is lost:** Real-time physical ball trajectory reading and rapid body ducking are replaced with probabilistic decision rolls.
## Implementation hints
Discrete court grid ( per half) keeps positional complexity minimal. First milestone: build the turn-based pass/strike state machine with fixed catch/dodge probabilities, then implement the *matka* 3-life endgame state.
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
Two Fires (Polish Dodgeball with Captains) (Poland). (n.d.). Games of Countries. https://gamesofcountries.com/games/pl-poland/dwa-ognie
@misc{gamesofcountries-pl-poland-dwa-ognie,
title = {Two Fires (Polish Dodgeball with Captains) (Poland)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/pl-poland/dwa-ognie}
}