Skip to main content
Formal Specification

Police and Thief — Formal Specification

Singapore · chase-tag · Confidence: high

← Back to game page

Implementation Suitability

Suitability: adaptation-requiredFidelity: discretizedGap-fills: 0
# Police and Thief — AI-optimized specification ## General idea Police and Thief is an asymmetric multi-agent predator-prey tag simulation on an obstacle-rich 2D grid containing a centralized Jail base. The Police coordinate search, interception, and guarding to incarcerate all Thieves, while the Thieves coordinate spatial evasion and high-risk diversionary rescue runs to liberate jailed teammates. ## Formal model - **Abstraction taken:** The urban environment is discretized as a 20×20 grid graph with static obstacles (pillars/walls) and a designated Jail zone at (0,0). Time proceeds in discrete ticks. - **Player/agent count:** 2 teams of 3 agents each (Team P: Police, Team T: Thieves). - **Turn model:** Simultaneous tick execution: all active agents select movement actions concurrently. ## Formal rules R1. Setup: 20×20 grid with obstacle cells O⊂V. Jail zone J={(0,0),(0,1),(1,0),(1,1)}. - Police spawn at Jail zone J. - Thieves spawn scattered across quadrant (10..19,10..19). - Time limit Tmax⁡=150 ticks. R2. Movement & Velocity: Each tick, un-jailed agents choose a movement step Δx→∈{(0,0),(±1,0),(0,±1)} into non-obstacle cells. Police speed = 1 cell/tick; Thief speed = 1 cell/tick. R3. Tag & Incarceration Resolution: - If a Police agent occupies the same or Manhattan-adjacent cell (‖x→p−x→t‖1≤1) as a free Thief, a tag occurs with probability P(tag)=0.90. - A tagged Thief is immediately marked `JAILED` and teleported to cell (0,0). R4. Jailbreak / Rescue Dynamics: - Any free Thief who enters cell (1,1) or an adjacent cell to a jailed Thief without being tagged on that tick triggers an immediate `JAILBREAK`. - Upon jailbreak, all currently jailed Thieves are instantly set to `FREE` and placed at (2,2), granting a 2-tick invulnerability buffer to disperse. R5. Win Conditions: - Police Victory: All 3 Thieves are in state `JAILED` simultaneously before Tmax⁡. - Thief Victory: At least 1 Thief remains `FREE` when tick counter reaches Tmax⁡=150. ## Edge cases - Tie at the end condition: Not applicable; either all thieves are jailed (Police win) or tick limit expires (Thief win). - A player with no legal move: In the event an agent is completely surrounded by obstacles and agents, the agent remains stationary (`WAIT`). - Repetition / cycles: Bounded strictly by the global tick limit Tmax⁡=150. - Simultaneous claims on the same resource or position: If a Police tags a Thief on the exact same tick the Thief enters the Jail zone, the tag takes precedence, preventing the jailbreak. - Player elimination mid-round: Jailed thieves are immobilized at (0,0) and take no actions until liberated by a teammate. - Resource exhaustion: Conserved count of 6 agents. - Termination guarantee: Guaranteed by the hard tick cutoff Tmax⁡=150. ## State representation - Persistent state: - `tick_counter`: integer 0..150. - `team_scores`: array of size 2 (integers ≥0). - Per-tick state: - `police_positions`: array of 3 coordinates in [0,19]2. - `thief_positions`: array of 3 coordinates in [0,19]2. - `thief_states`: array of 3 enums ∈{FREE,JAILED}. - `invulnerability_timers`: array of 3 integers. - Observable information: Partially observed (line-of-sight grid raycasting) or fully observable in simplified benchmark mode. ## Action space - Police: `move(direction)` ∈{UP,DOWN,LEFT,RIGHT,WAIT}. - Thieves: `move(direction)` ∈{UP,DOWN,LEFT,RIGHT,WAIT} (inactive while `JAILED`). ## Playability notes - Single-player-vs-AI: Fully natural; 1 human thief coordinating with 2 AI thieves against 3 AI police officers. - Group games (n>4): Easily scalable from 3v3 up to 10v10 by enlarging grid dimensions. - Physical-skill games: Physical sprinting and spatial hiding are abstracted into grid navigation and line-of-sight hiding. - What is lost: Adrenaline of breathless hiding behind stairwell railings and rapid physical hand tags. ## Implementation hints Discrete 2D grid world. Easily implemented with standard pathfinding (A*) for AI path planning and basic collision detection.

Download as JSON

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

Download JSON
Cite this page

Police and Thief (Singapore). (n.d.). Games of Countries. https://gamesofcountries.com/games/sg-singapore/police-and-thief

@misc{gamesofcountries-sg-singapore-police-and-thief,
  title = {Police and Thief (Singapore)},
  year = {n.d.},
  publisher = {Games of Countries},
  url = {https://gamesofcountries.com/games/sg-singapore/police-and-thief}
}