Formal Specification
King's Game — Formal Specification
Iceland · hide-seek · Confidence: low
← Back to game pageImplementation Suitability
Suitability: engine-readyFidelity: discretizedGap-fills: 7
# Kóngsleikur — AI-optimized specification
## General idea
A traditional Icelandic folk hide-and-seek and base-usurpation game. One player presides upon a royal throne (*kóngsstóll*), closing eyes and reciting a formal royal proclamation forbidding all subjects from occupying the throne. While the King ventures forth to locate and banish hidden subjects, the hiders attempt to stealthily sneak onto the vacant throne to overthrow the monarch and claim the crown for the following round.
## Formal model
- **Abstraction taken:** The physical domestic room or outdoor farmyard is discretized into a 2D coordinate space containing the central Throne node and surrounding hiding zones. Line-of-sight detection, throne guarding, and usurpation sprint races are resolved on discrete time-ticks. [gap-fill] Zone layout, throne proximity capture radii, and match scoring caps formalize folklore records.
- **Player/agent count:** agents (modeled as : 1 King, 5 Subjects).
- **Turn model:** Real-time ticked simulation across Royal Proclamation, Throne Guarding/Search, and Usurpation sprint phases.
## Formal rules
R1. Setup: The central Throne (*kóngsstóll*) is located at . The environment contains discrete hiding zones at distances meters [gap-fill]. Initially, Agent 0 is designated the King, seated at in state `PROCLAIMING`. All Subjects begin in state `HIDING`.
R2. Phase 1 — The Royal Proclamation & Counting:
- The King closes eyes at and recites the ancient proclamation for ticks [gap-fill]:
> *"Eg fyrirbýð öllum kóngsstól utan lands og innan, nema kónginum sjálfum!"*
- All Subjects use this 20-tick window to choose and occupy hiding zones.
R3. Phase 2 — The Search & Banishing (*Að fyrirbjóða*):
- At tick 20, the King transitions to `SEARCHING`, patrolling away from at speed .
- Detection: For any Subject in line of sight, the King detects the player with probability .
- When the King spots Subject without Subject being in an active sprint toward the throne, the King declares the royal ban (*"Ég fyrirbýð þér kóngsstól!"*).
- Subject transitions to state `BANISHED` (eliminated for the remainder of the active round) and must sit aside.
R4. Phase 3 — Usurping the Throne (*Að ræna kóngsstól*):
- At any time during Phase 2, any unbanished Subject may initiate a sprint toward the Throne at .
- If the King notices the sprint, the King immediately enters a footrace to reach to intercept the usurper.
- If the sprinting Subject reaches and spends tick occupying the Throne before the King can physically tag them (distance meter), the usurpation succeeds [gap-fill]:
- The King is immediately deposed (*úr tigninni*).
- The successful Subject is crowned the **New King** for the subsequent round.
- The round ends immediately with a Usurper Victory.
R5. King Retainment Victory:
- If the King successfully banishes all Subjects without anyone seizing the throne, the King achieves a Royal Retainment Victory and begins a new reign as King in the next round.
R6. Match Termination: [gap-fill] The match concludes after **10 rounds**. Players accumulate points for reigns maintained (as King) and successful coups executed (as Usurpers). The player with the highest score wins.
## Edge cases
- Tie at the end condition: If a sprinting usurper and the returning King arrive at the throne on the exact same tick, the King successfully defends the throne and the usurper is banished [gap-fill] (monarchic defense priority).
- A player with no legal move: Banished players wait aside; active subjects always have spatial movement available.
- Repetition / cycles: Bounded strictly because subjects are either progressively banished (reducing active hiders toward 0) or achieve a throne coup (ending the round immediately).
- Simultaneous claims on the same resource or position: If two subjects sprint to the throne simultaneously, the first to arrive claims the crown; if tied on the exact same tick, the player with the higher Agility attribute is crowned [gap-fill].
- Player elimination mid-round; turn order repair: Banished subjects are benched for the active round; upon round conclusion, all subjects return to active play for the new reign.
- Resource exhaustion: Throne is unique; player count is fixed and non-depleting across rounds.
- Termination guarantee: Guaranteed because each round terminates upon either (a) usurpation of the throne (single event) or (b) banishment of all subjects (monotonic elimination), capped by the 10-round ceiling (R6).
## State representation
- Persistent state:
- `round_number`: integer `[1..10]`.
- `current_king_id`: agent ID.
- `player_scores`: map `{agent_id: int}`.
- Per-round ephemeral state:
- `subject_states`: array of `{HIDING, SPRINTING_TO_THRONE, BANISHED}`.
- `king_position`: `(x, y)`.
- `subject_positions`: map `{subject_id: (x, y)}`.
- `throne_occupant`: optional agent ID.
- `round_status`: `{ONGOING, USURPED, KING_DEFENDED}`.
- `current_tick`: integer.
- Observable information:
- King observes only line-of-sight field of view and throne proximity.
- Subjects observe King's position, distance from throne, and banishment status of peers.
## Action space
- King: `patrol(x, y)`, `banish_subject(subject_id)`, `sprint_to_throne_intercept()`.
- Subject: `hide(zone_id)`, `sprint_to_throne()`, `claim_throne()`.
## Playability notes
- Single-player-vs-AI: Natural — human plays as the King managing risk vs territory exploration, or as a Subject timing an opportunistic coup while the King's back is turned.
- Group games (n>4): Plays up to 15 players naturally; reducing to 4 players (1 King, 3 Subjects) preserves all core tension.
- Physical-skill games: Sprint timing and visual cover utilization are abstracted into spatial coordinates and line-of-sight checks.
- What is lost in the adaptation: The solemn, humorous atmosphere of reciting medieval legalistic decrees (*"utan lands og innan"*) is formalized into a timing state constraint.
## Implementation hints
- Model King AI with a risk-sensitive distance constraint: .
- Throne usurpation is an asymmetric race problem resolved via distance-to-throne vs king's-distance-to-throne.
- Suggested first milestone: implement R1–R5 (counting, spotting and banishment, throne sprint race comparator, and crown succession).
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
King's Game (Iceland). (n.d.). Games of Countries. https://gamesofcountries.com/games/is-iceland/kongsleikur
@misc{gamesofcountries-is-iceland-kongsleikur,
title = {King's Game (Iceland)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/is-iceland/kongsleikur}
}