What it does
In the passenger mode, in the style of Bus Jam, a crowd stands on a floor plan and coloured buses arrive one at a time. A passenger with a free path of empty cells to an entrance can leave: they board the bus if it is their colour, or take one of a few waiting spaces if it is not. A full bus departs, the next pulls in, and any waiting passengers of its colour board at once. When the waiting spaces fill with the wrong colours, the level is lost.
In the vehicle mode, in the style of Bus Out, the buses are parked in a packed lot and the passengers stand in one
queue. A bus whose route out is clear of every other bus and wall drives into a free loading bay, and the front of
the queue boards whichever bay matches, one passenger at a time. The lot's route checks are the traffic-release
pack's, which comes with this one.
Every move goes through apply, which returns the events in order (a passenger waiting, boarding, a bus departing or
dispatched) for your game to animate, or a reason and no change at all. preview shows what a move would do,
legalActions lists every legal move with the wanted colour first, and deadlock explains a stuck position: which
colour is needed, what is waiting and who or what is blocked.
Features
- Two modes —
'passengers'for a crowd and arriving buses,'vehicles'for a parking lot and a single queue. - Seeded levels —
generateBoardingQueuebuilds a level from a seed and a difficulty, and replays its solution before returning it. - Four difficulties — easy to very hard, from 4 buses in 3 colours with 7 waiting spaces to 18 buses in 8 colours with 2.
- Three floor plans — a rectangle, aisles with an empty column every third, and a courtyard with a wall down the middle.
- Walking paths —
accessiblelists the passengers who can walk out, each with the path to animate. - Deadlock explanations — waiting spaces full, a walled-in queue, bays full or no matching bus, with what is needed and what blocks it.
- Hints —
solvereturns the rest of the level's known solution when it still applies, or searches for one within a budget. - Undo, redo and reset — and every invalid move is refused without changing the puzzle.
Good for
- Bus-boarding colour puzzles with a crowd and arriving buses, in the style of Bus Jam or Bus Escape.
- Parking-lot boarding puzzles, where buses drive out to bays and a queue boards them, as in Bus Out.
- Other colour-service queues — customers to counters, parcels to vans — wherever one item fills one seat of a matching container that leaves when full.
- Mobile puzzle sagas that need an endless supply of solvable levels at rising difficulty.
- 3D or 2D presentations alike, since the rules draw nothing.
Make it yours
A level is a configuration you can write by hand: the board's width and height, which cells are floor, where the
entrances are, each passenger's colour and position, the buses in arrival order with their seats, and the number of
waiting spaces. The floor can be any shape. A vehicle level takes a parking lot from traffic-release, the buses in
it, the queue's colours and the number of bays.
The generator takes a seed and a difficulty, and you can override any of its parameters: the mode, the floor plan, the number of buses, colours and seats per bus, the waiting spaces or bays, how far ahead colours are mixed into the crowd, and the parking lot's own generator settings.
Two quite different games: a gentle passenger level on the aisles floor plan with three colours and seven waiting spaces; and a hard vehicle level, a packed lot of buses with only a few bays and colours interleaved two buses ahead, where the order the buses leave is the whole puzzle.
A quick look
Generate a hard level, play a tap, and ask for a hint:
const level = generateBoardingQueue({ seed: 29, mode: 'passengers', difficulty: 'hard' });
const bus = createBoardingQueue(level.config, level.solution);
const tapped = bus.accessible()[0]!;
const turn = bus.apply({ type: 'passenger', id: tapped.id });
if (turn.valid) for (const e of turn.events) present(e); // waiting, boarded, departed
const hint = bus.solve(20000);
Works with
traffic-release— the parking lot and route checks behind the vehicle mode, and the pack to use when pieces only leave along routes with nothing to board.sliding-blocks— for cars that slide back and forth to make room.container-sort— for pouring colours between tubes.shelf-sort— for moving goods between shelves.
Good to know
- The generator makes a solid crowd on a board up to 10 cells wide, with the same seats on every bus and up to 8 colours. It has no obstacles or special passengers; author those in a level of your own, using a custom floor shape for obstacles.
deadlockdescribes the position now. A position can be hopeless while moves remain, and onlysolvecan say so; itsunsolvableis a proof only when the search finished within its budget.solvefinds plans quickly on generated levels but does not promise the shortest, and a large authored level may exhaust its budget.- The vehicle mode is turn-based: a dispatch is instant, and your game animates the route the bus takes.
- Assigned-seat swapping puzzles are a different mechanic and are not covered.






