Version 0.9.0 · work in progress

Giant Escape

A walled town on sloping ground, three 18-metre giants, and a fire that spreads the way fire does — cell by cell, with the wind, through whatever there is to burn. You command the giants. The town's people look for a way out, or don't. Built for the browser with three.js. The giants' walk is held to laws taken from real humanoid robot controllers, and replayed through MuJoCo to check the books.

  • Version0.9.0 — the first hosted release, 3 December 2026. A build under construction: it plays from the first town on, and its known bugs are listed below, as they are on the game's own start screen.
  • Playqalarc.com/games/giant-escape — desktop browser, keyboard and mouse, nothing to install. One game mode for now: get the people out alive.
  • The fireA cellular field on 48,400 one-metre cells, stepped at a fixed 20 Hz, deterministic by seed. Roads are firebreaks because they are bare, not because a script says so.
  • The walkA baked animation for the body, a gait that owns the ground, and 15 laws from MuJoCo-validated humanoid controllers. A MuJoCo rigid-body pass replays the game's own motion and reports where physics would object.
A giant strides through the burning town at dusk; two more giants and the town's wall stand behind it

The game

Type a seed. Every seed is its own town — walls, gates, roads, houses and keep laid out by the shape of the land — and a level begins: people leave their houses and look for a gate, and three giants walk in. A level is held when enough people are out past the border. Each level is a new town with a steeper ask, and before each one you take a single card that changes the rest of the run.

KeyWhat it does
1 2 3, then clickChoose a giant and order it to walk there. Giants also act on their own: they hunt the crowd and set fire to houses.
SpaceSmash — a shockwave from the selected giant.
F + clickFire: the giant's beam, aimed where you click.
H J LThe powers: wind, a tornado, a comet.
ERaise an earth wall.
CThe ground view — a camera at a person's eye level. For now it is only a camera: playing on the ground is coming soon.
EnterNext level, once a level is judged.
Zombie buttonSend a zombie in at a gate. Zombies bite; the townsfolk glow no colour, the zombies glow red.

The town finds its own way out: every person is steered by a navigation mesh over the real ground (Recast and Detour), re-cut as buildings come down. When a giant takes a house apart, the rubble blocks the lanes until a giant wading through grinds it clear.

How the fire is simulated

The fire is not a particle effect painted over the town. It is a simulation that runs whether or not anyone is looking: every square metre of the played area carries a heat, a fuel and a char, and everything you see burning is drawn from that state.

Flames standing along the road and on the houses of the town
Fire in the game's own camera. A front moving through the town: flames stand on the ground, up the walls of timber houses and along the road's verge. Every tongue is drawn from the field below it.
The walled town seen from above with fires burning and giants walking
The same field, seen whole. From the air the burnt ground reads as scorch where the fuel is gone, and roads stay green-free and unburnt because they carry almost nothing to burn.

The model

Fire is a cellular field on a one-metre grid: 220 × 220, so 48,400 cells over the played area, ±110 m. Each cell has three numbers. Heat rises toward 1 in a burning cell at 0.85 a second. Fuel is what there is left to burn, and it falls at 0.075 a second, give or take a quarter at random — about 13 seconds of flame from a full cell. Char is one minus the fuel left, and it stays: burnt ground is burnt.

A cell hotter than 0.5 tries to light each of its eight neighbours on every step. The chance is

dt × 0.34 × strength × wind × (0.4 + 0.6 × the neighbour's fuel)

where wind runs from 0.3 upwind to 3.2 straight downwind at full strength. A tired front also spends reach on every hop — 0.018 to 0.043 downwind, 0.04 to 0.10 across or against the wind — so a front can arrive somewhere and die. Ground that is bare, already burnt, or water never catches.

SettingValueWhy it is that
Grid1 m cells, 220 × 220Fine enough that a road 5 m wide is a real break; small enough to hold in one texture.
Time stepfixed 20 HzThe field advances in equal steps from an accumulator, clamped at 0.12 s. A stalled frame cannot make the fire jump.
Costper burning cellOnly the active set is visited each step. A quiet town costs nothing; a town fully alight is bounded by the grid.
Randomnessseeded (mulberry32)No Math.random. The same seed and the same ignitions give the same fire; the test suite checks the state byte for byte.
Windone vectorThe same wind drives the spread and the way every grass blade leans.

What there is to burn

Fuel is a property of the ground, read from the town itself. Open grass carries a full load. A worn road carries 0.02 — effectively bare — which is the whole reason a road acts as a firebreak: there is nothing on it to carry the front across. Steep soil carries less, down to 0.38. Buildings burn part by part: timber ignites, chars and fails where it stands; stone chars but never burns through; a burning house sets fire to the grass beside it. Trees light from hot ground, their canopy chars to soot and the crown carries flames.

From state to screen

The field is exported once per change as one byte-quad per cell — red is char, blue is burning-now, alpha is fuel left — in a single texture. Three different drawings read that one texture through one shared sampling function, with a world-space warp so the fire's edge is never a straight grid line: the ground's scorch; every grass blade, which burns, shrinks, turns to ash, and is not drawn at all where the fuel is gone; and the flames — instanced crossed tapered strips, each with its own up-axis, so fire stands up from the ground, out of a wall's face and normal to a roof slope, with a white-hot core, haze and ember glow, and smoke. The drawings are capped (2,200 flames, 1,400 smoke, 640 glow, 320 ground glow); the simulation underneath is not.

Where it is wrong. The smoke hangs in the air instead of rising and thinning out, and fire can start by itself. Both are on the known list, in the game and below.

How the giants move, and where robotics comes in

An animation clip on its own will put a giant's foot inside a hill. A physics engine on its own cannot animate anything. Giant Escape splits the job into four parts, ties them together with laws taken from controllers built for real humanoid robots, and then replays the result through MuJoCo to check the books.

Four parts

  1. The animationA 19 KB baked walk — the town's citizens' own walk, baked onto the giant's 65-joint skeleton — owns the body: arms, torso, timing.
  2. The gaitprocgait.js, plain JS, owns the ground: where each foot plants, on what slope, with no slide while it is down.
  3. The rigskinned-giant.js solves the clip's legs onto the gait's ankles in world space: a two-bone solve with a knee-speed limit.
  4. The meterfeasible.js, plain JS: 15 laws as arithmetic on the pose stream. Could a real biped do this?
  5. The witnessphysics_check.py: the game's own motion replayed through MuJoCo, a rigid body on real contacts.

Over uneven terrain

The gait is the part that knows about the ground, and it reads it every frame for every foot, from the same heightfield the town is built on. What it does with what it reads:

  • The sole goes on the ground's own plane. On a slope the foot is flat on the slope, not level with the horizon — on crests and cross-slopes too.
  • It lands heel first. The sole arrives toe-up and settles through its heel line over 0.35 s, then rolls over the toe as it lifts.
  • The toe pad has a limit. It follows the foot in swing, but never further toe-down than the ground under its tip allows.
  • Swing clearance. The heel line, the toe pivot and the pad's tip must each clear the ground under them; a sole still low lifts, eased.
  • Reach is corrected sideways, never down. When the leg cannot make the landing spot, the correction is taken horizontally ("in, not down"). An earlier version pulled it toward the hip and dropped the pad 9 cm under the ground.
  • Turning. A swinging foot turns with the body in the air and lands splayed by at most 0.45 radians; a planted foot pivots slowly, and only past that twist.

Where the laws come from

The rules the giants are held to are not invented for the game. They are the contact constraints two open-source humanoid controllers enforce, and both of those controllers were built and validated in MuJoCo:

  • humanoid-control — nonlinear model-predictive control with whole-body control, on the OCS2 framework. From it: a friction cone of μ = 0.7; a foot on the ground has zero velocity (no slip); a foot in the air carries zero force; every joint has a torque limit; stance and swing keep to gait timing.
  • LearningHumanoidWalking — policies trained by reinforcement learning in MuJoCo on the JVRC-1 and Unitree H1 robots. From it: the foot-force and foot-velocity clocks that say when a foot is really down, and the H1's joint ranges, which are the meter's limits.

The meter is those rules as arithmetic: two centres of mass (the true one, and the pelvis path with the legs hanging under it), the centre of pressure over a 170 ms window judged at its 95th percentile, sole lines tested against the heightfield, and the rig's own two-bone solve with its knee-speed limit. A harness runs both walks — the baked clip and a fully procedural one — over eleven drives: flat, ±20° slopes, two crests, a cross-slope, a steady turn, a turn about, fast, slow, and start·stop. It takes seconds and runs in the test suite on every change. On the uneven drives it reads: balance — the centre of pressure inside the stance sole for 95 % of single support, on both walks; contact and no penetration on the crests; foot yaw, legs clear and continuity on the turns. The game's own foot probe — the foot it drew against the ground it drew — passes 15 of its 16 runs.

The rigid-body pass: the game's motion, replayed through MuJoCo

The meter is arithmetic. MuJoCo is the witness that adds what arithmetic leaves out — angular momentum, the distribution of force over a sole's contact points, and torque. The game writes a trace of its own walk, and physics_check.py hands it to a rigid body:

  1. The traceAt 60 Hz: the pelvis, its heading, and where both ankles are.
  2. The bodyThe giant's leg chain — hip yaw, roll and pitch, knee, ankle pitch and roll, each side — the trunk as one rigid body with a human's mass distribution, 35,000 kg, four contact spheres a sole, μ = 0.7.
  3. Solve the legsThe pelvis is put where the game drew it and each leg is solved by damped least squares so its foot lies where the game's foot lies. The residual is the unreachable part.
  4. What the motion requiresInverse dynamics with contacts switched off: the force every joint would need, τreq.
  5. What the ground can giveThe forward constraint solver, with τreq applied: the contact forces the friction cone and one-way contacts permit.

τreq minus what the contacts gave, on the floating-base rows, is the missing wrench: what a real body of this motion would need from nowhere. The centre of pressure of the forces that are permitted, read in the loaded sole's own frame, is the ZMP law as the solver sees it. No policy is trained and no controller is tuned: the harness only replays and reports.

The rigid-body model MuJoCo is given: two capsule legs, a trunk block, a sole plate with four contact spheres under each foot, and a bar the height of a person
The body MuJoCo is given, at the widest instant of a stride on the game's own trace: the leg chain as capsules, the trunk's bulk above it, a sole plate with four contact spheres under each foot. The grey bar beside the rear foot is 1.7 m — a person.
Four charts over ten seconds of the walk: the load under each foot, the centre of pressure along the sole, the friction demand against the friction limit, and torque against a scaled human's peaks
What the pass reads, frame by frame, over ten seconds of the walk: the load the ground gives each foot; the centre of pressure from heel to toe, with the sole shaded; the friction the motion demands, against μ; and the torque the loaded leg needs, against a scaled human's walking peaks. Drawn by plot_check.py from the pass's own readings.
ReadingThe walk in the game (baked clip)The procedural walk
Frames replayed1,035918
Unreachable part of the legs0.00 mm0.00 mm
Missing wrench — force the ground cannot give, 95th percentile0.16 % of body weight0.08 %
Centre of pressure outside the sole0 % of single-support frames0 %
Friction demand over μ = 0.7 — median / 95th / worst0.21 / 2.25 / 37.60.24 / 1.05 / 5.79
Torque against a scaled human's peaks, 95th percentile — hip / knee / ankle1.21 / 3.49 / 1.330.94 / 1.70 / 1.46
Frames past a Unitree H1 joint rangenonenone

Readings of 3 December 2026, on the 18 m giant, on level ground. Torque per kilogram grows with size (weight times lever), so a human's walking peaks are compared after scaling by the height ratio — 10.65× here.

Read plainly. The walk is balanced: the ground never has to supply a force it cannot, and the centre of pressure never leaves the sole. It is not inside a scaled human's strength — the knee needs three and a half times a human's peak at the 95th percentile — and in the spikes it asks for more grip than μ = 0.7 gives. The giants are stronger and grippier than any real biped. That is stated here rather than tuned away.

What has and has not been replayed. The traces run through MuJoCo so far are level-ground walks. Over uneven terrain the checks are the meter's and the foot probe's — the same laws, solved in the game; the probe's one miss is a toe tip 11.6 cm under rising ground at 79 % of a swing, against a 10 cm law. Replaying the slope drives through MuJoCo, with the ground as a heightfield and the contact spheres on it, is the next step. It is on the list.

Where it stands

Version 0.9.0 is a live build under construction, published so it can be played and judged as it is. The game says so on its start screen, with the same two lists:

Known bugs

  • Smoke hangs in the air where it should rise and thin out.
  • Fire can start by itself.
  • A giant sometimes walks through a house instead of breaking it.
  • Playing on the ground is not in yet: for now C is a camera at eye level.
COMING SOON A giant seen from a person's eye level, forty metres away, walking through the burning town
Playing on the ground — coming soon. A camera at a person's eye level, forty metres from a giant. In 0.9.0 this is all the ground view is: a way to stand in the street and watch. Walking those streets, and casting from them, is next.

Credits

Where every part came from.

PartFromLicence
Engine, navigation, ambient occlusionthree.js; Recast and Detour by Mikko Mononen through recast-navigation-js; N8AO with postprocessingMIT and zlib
The giants' bodyThe character “Ch30” from Adobe Mixamo, as in DUSKRUNNER 2Adobe Mixamo terms — used inside the game, not redistributed separately
The giants' walk, the citizens and their animationQalarc's own mannequin with clips from Quaternius' Universal Animation Library, baked onto the giant's skeletonCC0
Town and castle piecesKenney — Fantasy Town Kit and Castle KitCC0
TypeRed Hat MonoSIL Open Font License
The real-terrain windowsCopernicus DEM GLO-30Produced using Copernicus WorldDEM-30 (c) DLR e.V. 2010-2014 and (c) Airbus Defence and Space GmbH 2014-2018; Copernicus Programme.
The rigid-body passMuJoCo; the laws quoted from the open-source humanoid-control and LearningHumanoidWalking controllersopen source
The fireGrown out of the Grass-Fire Lab—

Everything else — the gait, the meter, the town generator, the collapse engine, the fire model, the sound, which is synthesised as it plays — is Qalarc's, built in-house.