Commit Graph

11 Commits

Author SHA1 Message Date
joren
d6d62083c9 Refactor(Spel ADT): Add top-level game orchestrator with message-passing
Connects level (logic) with teken (graphics) via callbacks.
Follows snake-wpo adt-spel pattern exactly.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:53:21 +01:00
joren
48948a73a8 Refactor(Teken ADT): Isolate ALL graphics into single message-passing ADT
All rendering (maze, coins, key, pacman, UI, pause) consolidated here.
Grid-to-pixel conversion happens exclusively in this ADT.
Follows snake-wpo pattern with callback registration.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:53:05 +01:00
joren
40e7a2e9d9 Refactor(Level ADT): Consolidate all game logic into message-passing ADT
Combines game-logic, keyboard-handler, main-loop, and pause-menu into
single level ADT. Handles movement, collision, teleportation, coin/key
pickup, door opening, pause toggling, and time updates. No graphics.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:52:13 +01:00
joren
957c777938 Refactor(Tijdslimiet ADT): Encapsulate time limit as message-passing ADT
Pure logic ADT with verlaag!/verhoog! mutators, tijd-op? predicate,
and formatteer-tijd method. No graphics code.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:51:36 +01:00
joren
41133a2f09 Refactor(Score ADT): Encapsulate score as message-passing ADT without graphics
Pure logic ADT with punten getter and verhoog! mutator.
Uses punten-per-muntje constant. No graphics code.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:51:17 +01:00
joren
22394aae50 Refactor(Sleutel ADT): Encapsulate key as message-passing ADT without graphics
Pure logic ADT with positie, opgepakt? predicate, pak-op! mutator.
Random placement logic uses doolhof ADT. No graphics code.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:51:06 +01:00
joren
4d74e42fe1 Refactor(Pac-Man ADT): Encapsulate Pac-Man state as message-passing ADT
Pure logic ADT with grid-based positie, richting, beweeg! method.
All sprite/animation code removed - drawing responsibility in adt-teken.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:50:49 +01:00
joren
b342eeaeff Refactor(Doolhof ADT): Encapsulate maze as message-passing ADT without graphics
Pure logic ADT with grid data, cell predicates (muur?, muntje?, etc.),
mutators (cel-set!, verwijder-deur!), and voor-elke-cel iterator.
All graphics code removed - drawing responsibility moved to adt-teken.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:50:32 +01:00
joren
2ddbb1330c Refactor(Positie ADT): Add grid-based position ADT with message-passing dispatch
Constructor maak-positie returns dispatch closure with rij/kolom getters,
rij!/kolom! mutators, vergelijk? predicate, and beweeg method.
All coordinates are in grid units, not pixels.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:49:49 +01:00
joren
5870d63d9d Refactor(Constanten): Extract all magic numbers into centralized constants file
All hardcoded values (cell sizes, offsets, sprite scales, timing, score,
UI positions, cell type codes) are now named constants in an R7RS library.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 10:49:32 +01:00
joren
3abc9aae55 first commit 2026-03-23 10:28:54 +01:00