Drawing Jack in code: 26 poses and four flames for Stompkin

Stompkin's jack-o'-lantern is drawn by a Python program, pixel by pixel: five lobes, a face lit from inside, 26 poses and four flame stages.

Jack is the hero of Stompkin: a living jack-o'-lantern who stomps every winning group flat, and whose flame climbs with each stomp. The multiplier lives on him, so he has to read at a glance and move well in every frame. Every Jack sprite in the game is drawn by a Python program of about 480 lines.

A pumpkin made of five lobes

Each frame is a 72×88 pixel canvas, drawn from scratch at native resolution. At rest Jack's body is 50 by 40 pixels, built from five ellipse-shaped lobes: one in the centre and two pairs either side. For every pixel the program asks which lobe is nearest the viewer, and that lobe wins.

Light comes from the upper left. Each lobe is shaded on its own, lighter towards its left edge and darker at the bottom and the rim, and the result is cut into six hard bands of orange, from deep brown to a pale lit edge. No gradients, no dithering.

The ribs come for free. Where a lobe meets one that sits further forward, the pixel on the seam is pushed two bands darker, which gives the pumpkin's grooves as one-pixel lines of shading rather than drawn ink. Last comes the outline: every empty pixel that touches a coloured one turns night-ink indigo, so body, stem and flame share one clean silhouette against a busy board.

A face lit from inside

The carving is a set of polygons and ellipses cut out of the rind. Inside each opening there is a one-pixel dark wall along the upper edge, which reads as the thickness of the rind, then a ring of glow, then a hotter core. In the eyes a small white-hot pupil moves when he glances left or right.

Jack has five carvings: a grin for idle, a focused look before a stomp, a happy open mouth on landing, a round-eyed surprise when a feature lands, and a fanged blaze for the victory bounce. He has no arms or legs, so the face and the body do all the acting.

26 poses, each a new drawing

The program draws 26 poses: four breathing idles, two glances and a blink, two crouches, two leaps, the top of the arc, the fall, the contact and its follow-through, a rebound, four wobbles that settle him, two surprise frames, two leans and two victory frames.

Squash and stretch are never a scaled sprite. For the contact the body is redrawn 32% wider and a third shorter, with the lobes laid out again at that size, so every pixel is still a whole pixel from the same palette. The face squashes less than the body, so the carving stays readable at the moment that matters most.

Jack crouching before a stompJack stretched tall at the start of his leapJack squashed wide as he lands, with a happy open mouthJack rebounding upwards after the stomp
Four drawings from one stomp: crouch, leap, contact and rebound.

In the game each drawing holds for 50 to 90 milliseconds, with a 34 ms freeze on contact so the hit lands.

Four flames

Each stomp multiplies its win by Jack's flame, then the flame climbs one step up a ladder of 17: ×1, 2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 25, 30, 40, 50, 75 and 100. The art follows it in four stages, and the game picks the stage with one line: multiplier >= 50 ? 3 : multiplier >= 10 ? 2 : multiplier >= 5 ? 1 : 0.

  • ×1 to ×4: a candle glow in the face.
  • ×5 to ×8: an orange rim, and light spills onto the rind.
  • ×10 to ×40: a red rim, a white-hot core and a flame tongue above the stem.
  • ×50 and up: ghost-blue fire, a wider spill and a tall teal flame with two side licks.
Jack at ×1, with a candle glow in his faceJack at ×5, with orange light spilling around his faceJack at ×10, with a red flame tongue above his stemJack at ×50, with ghost-blue fire and a tall teal flame
The same idle pose at ×1, ×5, ×10 and ×50.

The two burning stages get three flicker drawings of every pose, so the tongue sways while he breathes. In the base game the flame starts at ×1 on every spin and goes out when the spin ends; in Hallow Night free spins it keeps every step it climbs until the feature ends.

Whole pixels only

With flicker frames and double-size drawings for big moments and store art, the program makes 296 drawings, and the same 296 every time it runs: there is no randomness in it. The double-size Jack is drawn again at twice the resolution, not enlarged.

In the game the scene is rendered at its native pixel size and enlarged by a whole number, 3× on a 1280×720 screen and 4× at 1920×1080, so a Jack pixel is always a square of identical screen pixels.

Jack also lives at the bottom of this site: click him to stomp him up the ladder. For the numbers behind his game, read how we test a slot's math.

18+ only. Stake.com is not available in every country, including the US, UK and Australia. Gambling can be addictive, so play responsibly. Responsible gambling on Stake

The games in this post

Coming soon to Stake

Jack, a living jack-o'-lantern, stomps every winning group flat in a midnight pumpkin patch. Each stomp stokes his flame from ×1 to ×100, and in Hallow Night free spins it never resets.

Grid
6×5 cluster tumble
Max win
15,000×
RTP
96.50%
Bonus
Hallow Night free spins

More from the devlog