# Three-Level Tactical Puzzle — draft 0.1 — Game Design Document

QUBU educational example: a fictional project, not an announced game or a completed player test.

## 1. Genre, platform and scope
Windows PC; single-player, offline tactical puzzle. First slice: 3 levels, 1 enemy type, 5×5 grid. Excluded: accounts, PvP, random maps, item economy and a shop.

## 2. Player promise
Read the enemy’s announced move and reach the exit within eight moves.

## 3. Core loop
Click an adjacent empty horizontal or vertical square; a valid move spends 1 move. No diagonals. Order: player moves → enemy moves to the previously marked square → check collision → check exit → show the next enemy target. Collision loses and takes priority over reaching the exit on the same turn. Lose if the eighth move ends outside the exit.

## 4. Progression and saving
Save completed levels. Do not save a turn in progress: reopening an unfinished level resets the player, enemy and 8-move allowance to their initial state.

## 5. Resources and economy
The only limited resource is 8 moves. Invalid and diagonal clicks spend no move and do not advance the enemy. No currency, item purchases or paid advantage.

## 6. Screens and feedback
Level selection, playing, win and loss states. Update remaining moves every turn. Show the enemy’s next target with both an arrow and a pattern, never color alone. Restart resets player, enemy and moves.

## 7. Test question and success measurement
Plan: a small observation session with 5 people, not statistical evidence. Before the first move, ask each participant to point to the enemy’s next square. Record the misunderstood turn and any help needed. If the target is unclear, fix the indicator before adding levels. No test results or retention measurements exist yet.

## 8. Planned events
Planned, not implemented: move_attempt (level_id, turn_index, valid); move_resolved (level_id, turn_index, collision); level_end (level_id, outcome). Purpose: separate invalid moves, collisions and level outcomes. Creating this document adds no data-collection code.

## 9. Edge cases and tests
Invalid/diagonal click → moves and enemy unchanged. Eighth valid move reaches exit without collision → win. Collision on that same turn → loss. Restart → initial player/enemy/8 moves. Close and reopen app → completed levels remain, unfinished level resets. Target remains understandable without color.

## 10. First-slice acceptance criteria
3 playable levels; turn-order and final-move tests pass; restart and saving behavior verified; arrow and pattern visible; observation misunderstandings recorded and the indicator decision added to the document.
