Escapement - Generated Clockwork Gear Puzzles, for GameMaker
A downloadable asset pack
A locked door is usually a switch and a line of text. Escapement turns it into a clockwork mechanism the player has to finish: a brass plate with fixed arbors, a tray of loose wheels, a mainspring that drives, and a payoff that only moves when the train is right. Every puzzle is generated from a seed and cannot be unsolvable. Pure GML.
The rules are learned by looking. A wheel meshes only when its size fits the gap between two arbors; every wheel turns the opposite way to the one driving it; the payoff turns one way only, so a train that reaches it the wrong way round stops dead and the pawl holds; close a loop of an odd number of wheels and the whole train jams. From grade III the plate hides a second route to the payoff that arrives turning the wrong way. Use it for vault doors, clock towers, observatories, portcullises, or a whole puzzle game.
// Create: open a puzzle (the same seed always gives the same puzzle)
my_puzzle = esc_open({ seed: "vault door", grade: 3, payoff: "lock" });
// Step: run it; when the player leaves, read the result
esc_step(my_puzzle);
if (esc_closed(my_puzzle)) { my_result = my_puzzle.result; esc_free(my_puzzle); my_puzzle = undefined; }
// Draw GUI: the scene is 816 x 624 at scale 1; draw it anywhere, at any scale
esc_draw(my_puzzle, 0, 0, 1);
What your players see
- Every puzzle is generated, laid around a working train so a solution always exists: five grades, from three wheels and a spare to six wheels, a wrong-way trap route, dead-end arbors and spare wheels that fit nowhere.
- Every wheel is drawn: 8 tooth counts x 8 web styles (solid with index dots, three to six spokes, curved spokes, round windows, a cross) x 5 metals, each with circular graining, a raised rim, a screwed hub and a timing mark, a cast shadow and a fixed glint. 320 loose wheel designs, plus the mainspring barrel.
- Four payoffs with their own moving parts: a strongroom bolt that draws back behind a keyhole escutcheon and a SHUT / DRAWN window; a tower clock whose hands wind round to the hour; an orrery whose planets come into conjunction; a portcullis winch whose counterweight rises.
- The plate in brass, steel, bronze, verdigris or gunmetal: brushed finish, Geneva stripes, an engraved border, corner screws, jewelled arbors with ruby bearings, an engraved arrow for the mainspring and a hint showing which way the payoff must turn.
- When it is wrong, it shows: the stuck train shakes, a red halo marks the pawl or the jamming mesh, and the line under the plate says why.
- Arrow keys and Enter, or the mouse: click an arbor, then a wheel in the tray. On mobile exports a first finger reads as GameMaker's mouse, though we have only built and tested Windows.
Built to plug in
- Five calls:
esc_open,esc_step,esc_draw,esc_closed,esc_free. The result says whether it was solved and where every wheel was left; hand that back to carry on later, so a half-finished mechanism waits in your save. - Choose the seed (a word or a number), the grade, the payoff, the metal, the title, the drive speed, whether the player may leave unsolved, and a sound hook (place, lift, refuse, solve, cursor). Scripted input for tutorials or replays.
- The rules are callable on their own (pure GML, no drawing): generate, evaluate, can-place, a solver, and every drawing function is public.
- Opening a puzzle takes a moment: about 2 to 2.5 s on our shared test machine, because the plate and every wheel are drawn once at twice the size. The demo shows a wait card first. After that a frame costs about 0.2 ms.
- Raw, readable source with a header on every public function. THE CLOCKMAKER'S BENCH demo room: four mechanisms, five grades, solved jewels, and a half-set train remembered.
Tested
- Igor package build clean on the shipped source, and proven able to fail.
- In-engine assertions on a real built exe, held to our RPG Maker MZ original run in Node: 300 generated puzzles field for field, 300 scripted placements (solved, jammed and wrong-way trains), 10,552 placement checks and the solver node for node. Every puzzle solvable.
- The drawing held to the original too: 243 drawings, 16,173 paint operations compared one by one.
- All four payoffs played to the end by scripted mouse input; the pawl, the jam, refusals, the keyboard, leaving and carrying on.
- A blank project that installed the package the way you will and ran the Readme's own code, with ink counted on everything it drew.
- 232 adversarial calls against the documented functions with zero crashes.
Requirements
GameMaker 2024.14 or newer (built and tested against runtime 2024.14.4.268, VM, Windows). Pure GML; no shaders, no extensions, no DLLs, no sprites to import. Import the .yymps, put rm_esc_demo first, press Play: THE CLOCKMAKER'S BENCH. Escapement makes no sound of its own; hook your own in.
One commercial licence, unlimited games, no attribution required. Everything the package draws in your game is yours to ship, including on your store page and in your trailers.
Paid, from the same studio
- Escapement for RPG Maker MZ ($11.99): the original, run from an event.
- Scales ($11.99): weighing puzzles on a drawn brass balance, for GameMaker.
- Jigsaw ($9.99): any picture cut into a generated jigsaw on a drawn table, for GameMaker.
- Horologe ($14.99): drawn clockwork machines that run, for GameMaker.
More GameMaker systems at csaf.itch.io.
AI disclosure: the code, the cover illustration and the interface text were produced with AI assistance. Every screenshot and the GIF were rendered by the product itself. Type: Cinzel and Alegreya (SIL OFL 1.1), notices included.
| Published | 2 days ago |
| Status | Released |
| Category | Assets |
| Author | CSAF — Core Systems Asset Factory |
| Made with | GameMaker |
| Tags | clockwork, GameMaker, gear, gml, machine, mechanical, mechanism, minigame, puzzle-game, sourcecode |
| Languages | English |
| AI Disclosure | AI Assisted, Code, Graphics, Text |
Purchase
In order to download this asset pack you must purchase it at or above the minimum price of $11.99 USD. You will get access to the following files:







Leave a comment
Log in with itch.io to leave a comment.