Formal Specification
The Pig (Romanian Pastoral Stick-and-Hole Game) — Formal Specification
Romania · stick-team · Confidence: high
← Back to game pageImplementation Suitability
Suitability: engine-readyFidelity: discretizedGap-fills: 2
# Poarca — AI-optimized specification
## General idea
A spatial, stick-and-ball territory defense game on a circular graph topology. A central pit is surrounded by perimeter hole nodes. guardian agents protect their assigned holes and deflect an incoming ball, while a single mobile swineherd agent tries to either drive the ball into the central pit or steal an unguarded hole when a guardian lifts their stick to strike.
## Formal model
- **Abstraction taken:** Field modeled as a star-and-ring graph with center node (Central Pen) and perimeter nodes . Ball position is a 2D coordinate . Stick defense is modeled as a binary state per guardian (`stick_in_hole` vs `swinging_at_ball`).
- **Player/agent count:** 1 Swineherd () and Guardians (, default ).
- **Turn model:** Simultaneous tick-based simulation.
## Formal rules
R1. State Topology:
- Center pit node .
- Perimeter nodes for ().
- Ball position .
- Per Guardian : `assigned_hole = i`, `stick_planted` .
R2. Swineherd Actions:
- `dribble_ball(dx, dy)`: Apply vector impulse to ball toward .
- `steal_hole(hole_id)`: Precondition: Swineherd is within distance of and Guardian has `stick_planted == False`.
R3. Guardian Actions:
- `hold_hole()`: Keep stick planted in hole (`stick_planted = True`). Hole is completely protected from theft, but guardian cannot strike the ball.
- `strike_ball(power, direction)`: Lift stick (`stick_planted = False`) for 2 ticks to strike ball away from .
R4. Ball Mechanics & Goal:
- If ball enters distance from center :
- Swineherd scores an instant Goal Win. Round ends; Swineherd wins 2 points.
R5. Hole Theft & Role Transfer:
- If Swineherd executes `steal_hole(i)` while has `stick_planted == False`:
- Hole is stolen. Guardian becomes the new Swineherd (). The previous Swineherd becomes Guardian of hole . Round resets with ball in neutral territory.
R6. [gap-fill] Turn Limit: Hard limit of 300 ticks per round. If tick 300 expires with no goal or hole theft, 1 point is awarded to the collective Guardians, and roles rotate clockwise.
## Edge cases
- Tie at the end condition: Not applicable — goal and hole-theft events are mutually exclusive absorbing transitions.
- A player with no legal move: `hold_hole()` is always a legal default action for guardians.
- Repetition / cycles: Bounded by the 300-tick round cap (R6).
- Simultaneous claims on the same resource or position: If Guardian attempts to re-plant stick on the exact same tick the Swineherd attempts `steal_hole`, [gap-fill] a priority check resolves the contest.
- Player elimination mid-round; turn order repair: Not applicable (roles transfer dynamically; player count remains constant).
- Resource exhaustion: Not applicable.
- Termination guarantee: Enforced by the finite tick ceiling ().
## State representation
- Persistent state:
- `swineherd_id`: Integer index .
- `hole_occupants`: Array of integers mapping perimeter holes to guardian IDs.
- `scores`: Array of integers.
- Per-tick ephemeral state:
- `ball_pos`: `[x, y]`.
- `ball_vel`: `[vx, vy]`.
- `guardian_stick_status`: Array of booleans.
- `tick`: Integer counter.
- Observable information: Fully observable.
## Action space
- Swineherd: `dribble_ball(vx, vy)`, `steal_hole(i)`, `move(dx, dy)`.
- Guardians: `hold_hole()`, `strike_ball(power, angle)`.
## Playability notes
- Single-player-vs-AI: Highly engaging risk/reward decision space. Guardian AI must balance fear of hole theft against ball interception urgency.
- Group games (n>4): Smoothly parameterizes for guardian agents.
- Physical-skill games: Physical crook swinging and ball dribbling converted into positional vector dynamics and vulnerability timing windows.
- What is lost: Physical dust, wooden club clashing noises, and pastoral banter.
## Implementation hints
- Implement as a simultaneous-step 2D physics simulation with circular hole triggers.
- Guardian heuristic: Only strike ball when trajectory strictly intersects central pen within ticks.
Download as JSON
Download the full game corpus entry for this game as structured JSON.
Download JSONCite this page
The Pig (Romanian Pastoral Stick-and-Hole Game) (Romania). (n.d.). Games of Countries. https://gamesofcountries.com/games/ro-romania/poarca
@misc{gamesofcountries-ro-romania-poarca,
title = {The Pig (Romanian Pastoral Stick-and-Hole Game) (Romania)},
year = {n.d.},
publisher = {Games of Countries},
url = {https://gamesofcountries.com/games/ro-romania/poarca}
}