tilttek / escape-room-bundle
tilttek/escape-room in Symfony: rooms, bookings, a host console, live hint screens, countdowns that end on time and a leaderboard by consent.
Package info
github.com/TiltTek/escape-room-bundle
Type:symfony-bundle
pkg:composer/tilttek/escape-room-bundle
Requires
- php: >=8.5
- ext-mbstring: *
- ext-sodium: *
- doctrine/dbal: ^4.5
- phil/resource: ^0.1@dev
- psr/clock: ^1.0
- psr/event-dispatcher: ^1.0
- psr/log: ^3.0
- symfony/config: ^8.2
- symfony/dependency-injection: ^8.2
- symfony/http-foundation: ^8.2
- symfony/http-kernel: ^8.2
- symfony/routing: ^8.2
- symfony/security-csrf: ^8.2
- symfony/service-contracts: ^3.6
- tilttek/escape-room: ^0.1@dev
- tilttek/puzzle-builder: ^0.1@dev
- twig/twig: ^3.21
Requires (Dev)
- doctrine/doctrine-bundle: ^3.3
- doctrine/orm: ^3.7
- phil/privacy-bundle: ^0.1@dev
- phil/reservation: ^0.1@dev
- phil/ux-kit: >=0.5.0-alpha <1.0
- phpunit/phpunit: ^13.4
- symfony/browser-kit: ^8.2
- symfony/cache: ^8.2
- symfony/clock: ^8.2
- symfony/console: ^8.2
- symfony/css-selector: ^8.2
- symfony/dom-crawler: ^8.2
- symfony/event-dispatcher: ^8.2
- symfony/framework-bundle: ^8.2
- symfony/mercure: ^0.10
- symfony/messenger: ^8.2
- symfony/rate-limiter: ^8.2
- symfony/scheduler: ^8.2
- symfony/translation: ^8.2
- symfony/twig-bundle: ^8.2
- symfony/ux-twig-component: ^3.7
- symfony/yaml: ^8.2
Suggests
- doctrine/orm: To add the tables of the escape rooms to the schema the ORM generates, and so to the migrations
- phil/privacy-bundle: To export and erase a member's games, results, bookings and screen messages with the rest of their account
- phil/reservation: To book the sessions of the rooms as intervals of a bookable resource, kept in Doctrine DBAL
- phil/ux-kit: For the recipes Card, Badge, Button, Alert and Celebration the screens are built of, through the Symfony UX Toolkit
- symfony/console: For the command that ends the games whose countdown reached zero
- symfony/mercure-bundle: For the hub the hint screen is told of each move of the console
- symfony/rate-limiter: To limit the guesses of a team across the processes of the application
- symfony/scheduler: To end the games whose countdown reached zero from Symfony Scheduler
- symfony/stimulus-bundle: For the controllers of the host console and of the hint screen
- symfony/translation: To translate the texts of the screens
- symfony/ux-twig-component: For the screens, built of the recipes of a kit of the Symfony UX Toolkit
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-11-21 03:06:16 UTC
README
Escape rooms for a Symfony application: the host's console, the hint screen in real time, bookable sessions, and a public leaderboard by the team's consent.
tilttek/escape-room-bundle integrates tilttek/escape-room with Symfony. The rooms — their scenario of puzzles, time,
penalties and team sizes — are written in the configuration, or given by the application's own catalog. Each game is
kept in Doctrine DBAL as the plain values the library writes, in UTC, with the moment its countdown reaches zero; the
results of the teams that escaped and what the hint screen shows are kept beside it, in five tables the bundle adds to
the schema the ORM generates. GameDesk plays each move by the game's identifier: it reads the game, moves it, writes
it back, records the result of an escape, and tells the screens.
The host drives a game from a console — push a hint, skip a puzzle, send a message, clear the screen, pause, resume, end
the game —, each form working without a script and sent in the background by a Stimulus controller. The hint screen in
the room shows the countdown, the hint or the message, and celebrates an escape with the Celebration of the PHIL UX
kit; it hears of each move through Mercure when a hub is there, or reads the game again at intervals. A schedule for
Symfony Scheduler ends the games whose countdown reached zero, once each. The sessions are booked on phil/reservation
when it is installed, under one lock per session in the database. The public leaderboard shows a team only once it
agrees, and it may change its mind; a member's games, results, screens and bookings are exported and pseudonymised with
their account through phil/privacy-bundle.
It is for a Symfony application that runs escape rooms, in a venue or online. The library alone suits an application without Symfony.
It requires tilttek/escape-room, Doctrine DBAL, Twig and Symfony's container, HTTP kernel, routing and CSRF; the ORM,
the console, Symfony Scheduler, Mercure, the rate limiter, Twig components, phil/reservation and phil/privacy-bundle
are optional, and the bundle registers what uses them only when they are installed.
Status
| Part | State |
|---|---|
| Configuration of the rooms, the stores, the access and the integrations | Implemented and tested |
GameDesk: the moves of a game by its identifier, the results, the hint screen, the expiries, the leaderboard |
Implemented and tested |
DbalGameStore, DbalResultStore, DbalScreenStore, DbalSeatLedger and the five tables, with the schema listener |
Implemented and tested |
| The memory stores for tests, reset between two requests of a worker | Implemented and tested |
The reservations on phil/reservation, wired when it is installed |
Implemented and tested |
The schedule tilttek_escape_room on Symfony Scheduler and the command tilttek:escape-room:expire |
Implemented and tested |
| The console and the hint screen, built of the kit's recipes, with their Stimulus controllers | Implemented and tested |
| The moves told through Mercure, the hub detected | Implemented and tested |
| The consent and the public leaderboard | Implemented and tested |
Export and erasure of a member for phil/privacy-bundle |
Implemented and tested |
| A Flex recipe | Prepared in recipe/0.1 |
Documentation
| Document | What it covers |
|---|---|
| Installation | Requirements, installing, the routes, the tables and the access. |
| Configuration | Every option, with an example. |
| Games | GameDesk: starting a game, its moves, the results and the leaderboard. |
| Screens | The console, the hint screen, the consent and the leaderboard pages; their controllers and events. |
| Real time | Mercure, the topics, and the screens without a hub. |
| Bookings | The reservations of the sessions on phil/reservation, or the application's. |
| Scheduling | The schedule and the command that end the games whose countdown reached zero. |
| Database | The five tables and what each column holds. |
| Accessibility | What the screens do for every player. |
| Privacy | What is exported and pseudonymised for a member. |
| Extension points | What an application replaces. |
| Reference | The classes, services, routes and exceptions. |
| Testing | The bundle's tests, and testing an application. |
Quick start
# config/packages/tilttek_escape_room.yaml tilttek_escape_room: access: App\EscapeRoom\Access rooms: cell: title: The cell duration: 1800 scenario: { id: cell, finale: door, puzzles: [{ id: door, title: The door, answers: [key], hints: [{ text: Under the bed }] }] } schedule: { enabled: true }
$desk->start('g-01J8', 'cell', ResourceReference::of('team', 'owls')); // The host opens /escape-room/console/g-01J8; the room shows /escape-room/screen/g-01J8.
Requirements
PHP 8.5 or later, Symfony 8.2, Doctrine DBAL 4.5.
Contributing
Contributions are welcome on the PHIL monorepo: read the contribution guide and the code of conduct. Report a vulnerability privately, as the security policy explains, never in a public issue.
License
MIT, © Philippe Gamache, doing business as Le Gnome Archiviste; a Tilttek project. See LICENSE.