Formal Specification
Kick the can (Finnish tin-can hide-and-seek) — Formal Specification
Finland · hide-seek · Confidence: high
← Back to game pageImplementation Suitability
Suitability: engine-readyFidelity: discretizedGap-fills: 3
# Purkkis — AI-optimized specification
## General idea
A dynamic outdoor hybrid game combining hide-and-seek, sprint racing, and ball kicking. At the start, an uncaught player kicks a ball away from a base can (*purkki*). While the seeker runs to retrieve the ball and return it to the can, the other players scatter to hide. When the seeker spots a player, both race back to the can to tag it; however, any free hider can sprint in and kick the ball away, shouting *"Purkki auki!"* (Can open!) to instantly liberate all captured prisoners and force the seeker to chase down the ball again.
## Formal model
- **Abstraction taken:** The physical terrain is discretized into a 2D obstacle grid with raycast line-of-sight (LOS). The ball is modeled as an entity with position and velocity. Kicking applies a directional impulse vector, and ball retrieval requires moving to the ball's cell and carrying it back to the base can coordinate .
- **Player/agent count:** agents (), comprising 1 Seeker and Hiders.
- **Turn model:** Simultaneous discrete execution per tick.
## Formal rules
R1. **Initial Setup & Opening Kick:**
- Base can is located at coordinate .
- At tick , a designated hider executes `kick_ball(direction, power)`, projecting the ball to coordinate at distance cells from .
- All Hiders immediately disperse into the grid to seek hiding positions behind occluding obstacles.
- The Seeker is assigned role `Retrieving`.
R2. **Ball Retrieval Phase:**
- While in `Retrieving` state, the Seeker cannot spot or capture any players.
- The Seeker navigates to the ball's coordinate , picks up the ball, carries it back to base cell , and places it down.
- Once the ball is placed at , the Seeker transitions to the `Hunting` phase.
R3. **Spotting and Can Tagging:**
- In the `Hunting` phase, if the Seeker gains unoccluded LOS to an uncaught hider , the Seeker executes `spot(H_j)`.
- The Seeker must return to cell and execute `tag_can(H_j)`.
- If completed before reaches , transitions to state `jailed` at the prison zone near .
R4. **The Jailbreak Kick (*Purkki auki*):**
- Any uncaught hider may move to cell at any time.
- If reaches while the ball is at and executes `kick_ball(direction, power)`:
- The ball is projected away to a new distant coordinate .
- All agents currently in `jailed` state immediately transition to `free` status.
- The Seeker immediately reverts to the `Retrieving` state and must fetch the ball back to before hunting can resume.
R5. **Action Conflicts:** [gap-fill] If Seeker and Hider reach base can simultaneously on the same tick, the Hider's `kick_ball()` action resolves first, successfully triggering the jailbreak and resetting the Seeker.
R6. **Round End & Role Transfer:**
- The round ends when all hiders are simultaneously `jailed` and the ball rests at .
- [gap-fill] The first player who was jailed during the round (and not subsequently freed) becomes the Seeker for the next game.
## Edge cases
- **Tie at the end condition:** Not applicable — Seeker wins if all hiders are in jail; hiders avoid loss as long as at least one hider successfully triggers rescues or remains uncaught.
- **A player with no legal move:** Jailed players execute `noop`. Active players blocked by obstacles have (stand still) as fallback.
- **Repetition / cycles:** [gap-fill] To prevent infinite rescue loops, a global limit of ticks (or maximum 4 jailbreak kicks per round) is enforced. If reached, all un-jailed hiders win.
- **Simultaneous claims on the same resource or position:** Handled by R5 (kick takes precedence over tag). Multiple hiders can occupy base cell simultaneously.
- **Player elimination mid-round; turn order repair:** Jailed players become inactive observers; tick processing continues for all remaining active agents simultaneously.
- **Resource exhaustion (pieces, tokens, space, time):** Exactly 1 ball and 1 base can. Time bounded by .
- **Termination guarantee: why the game provably ends:** Monotonic progress is enforced by the hard tick ceiling and the maximum jailbreak count.
## State representation
- **Persistent state:** Grid terrain map; base can coordinate ; tick counter ; total jailbreaks executed; match status.
- **Per-player state:** Position ; role ; status ; carrying-ball flag (Seeker); order of capture index.
- **Ball state:** Position ; in-transit status; at-base flag .
- **Observable information:** Imperfect information. Seeker observes obstacles and ball in local LOS. Hiders observe local LOS and global announcements of can tags and jailbreak kicks.
## Action space
- `move(dx, dy)`: where .
- `pick_up_ball()`: (Seeker only) valid when in same cell as ball.
- `place_ball_at_can()`: (Seeker only) valid when at and holding ball.
- `spot(target_id)`: (Seeker only) valid when in Hunting phase and target is in LOS.
- `tag_can(target_id)`: (Seeker only) valid when at with ball in place and target is spotted.
- `kick_ball(direction, power)`: (Hider only) valid when at and ball is at .
- `noop()`: wait/idle.
## Playability notes
- **Single-player-vs-AI:** Highly playable. Human as Seeker balances patrol distance from the can against the risk of an undetected hider kicking the ball; human as Hider times tactical sprint-kicks.
- **Group games ():** Reduces naturally to 2 agents (1 Seeker vs 1 Hider), preserving the core cat-and-mouse tension around the central can.
- **Physical-skill games:** Ball kicking physics is abstracted into a directional dispersion vector .
- **What is lost in the adaptation:** The physical sound of the tin can rattling, the satisfaction of a full-boot soccer strike, and the scramble of diving behind physical bushes.
## Implementation hints
- Model ball retrieval as a simple pathfinding target for the Seeker agent.
- Branching factor: movement actions + discrete interaction triggers per tick.
- Suggested first milestone: Implement the ball kicking and retrieval loop on a 20×20 grid, verifying that the Seeker correctly transitions between Retrieving and Hunting states.
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
Kick the can (Finnish tin-can hide-and-seek) (Finland). (n.d.). Games of Countries. https://gamesofcountries.com/games/fi-finland/purkkis
@misc{gamesofcountries-fi-finland-purkkis,
title = {Kick the can (Finnish tin-can hide-and-seek) (Finland)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/fi-finland/purkkis}
}