Waking Rocky…

Rocky

Eridian · Project Hail Mary · x 0.0 · z 0.0

Rocky

What it is

Rocky is the Eridian from Andy Weir's Project Hail Mary, built procedurally in three.js: a rock carapace carried on five legs that each solve their own inverse kinematics, so the gait emerges from the geometry rather than from a baked animation.

Walk him around and the camera follows; the legs find their own footing as the body turns.

Inverse kinematics is what makes it read as a creature rather than a model. Each leg gets a target on the ground, and the joints are solved backwards from that target every frame, so the body can turn or lift and the feet stay planted until they need to step. Nothing about the walk is recorded — change the stride length or the body height and the gait reorganises itself around the new geometry.

The carapace is generated too, not modelled: a dodecahedron is displaced by a sum of three sine terms, so the silhouette never reads as a primitive. That displacement is deliberately deterministic rather than random — neighbouring facets have to evaluate a shared vertex identically or the flat-shaded shell splits open along its seams, and the boulder field is seeded for the same reason, so the terrain is the same on every visit. Five legs rather than four or six is Weir's detail, and it changes the gait: with an odd number there is no symmetric trot, so two legs are always following three and the walk keeps a rolling, slightly off-balance quality.

How to use it

  • Walk with the arrow keys or WASD.
  • Drag to orbit the camera.
  • Scroll to zoom in and out.
webglthree.jsr3f3dproceduralcharacterkeyboardinteractive

More experiments

See every experiment