Skip to content
Tech News
← Back to articles

Our 2D game character grew 3% taller every time he walked

read original get Game Character Growth Figurine → more articles
Why This Matters

This article highlights a common challenge in 2D game development: managing inconsistent sprite canvases from multiple artists. The bug caused the main character to appear unnaturally tall and float, affecting game feel and immersion. Fixing this required understanding sprite dimensions and implementing more robust scaling and positioning logic, emphasizing the importance of standardized asset workflows in the industry.

Key Takeaways

We’re working on an adventure game, Leonardo’s Moon Ship. The player character, Leo, has the usual pile of animations: idle left and right, walk in four directions, a couple of stair anims. Since implementing the basics of the character, Leo has had this slightly cursed behaviour where he’d grow about 3% taller the moment he started walking, then shrink back when he stopped. His feet would also lift off the ground by up to 27 pixels depending on which way he was facing. Not enough to be obviously broken in a screenshot. Exactly enough to make the game feel wrong.

That’s the bug overlaid on itself. The red ghost is the naive setup. The blue is the fixed version. When Leo’s idle they sit on top of each other. The second a walk anim kicks in the red drifts up and out of place.

Why a single scale falls over

The animations came from the artists on wildly inconsistent canvases. Not the character, the canvas the character was painted on. Here’s the actual sizes:

idle_right: 675x1095, character tight-cropped

idle_left: 616x1094, basically the same character, slightly different crop

walk_right and walk_left: 1920x1200, but Leo himself is only about 700x1088 and floating somewhere inside all that transparent space

walk_up: 664x1202

walk_down: 664x1202

This is normal. Artists work in whatever canvas size makes sense for the motion they’re drawing. Walk cycles need horizontal room for the stride, idle frames don’t. And good luck enforcing a single canvas size across hundreds of frames and constant revisions.

... continue reading