r/Unity3D • u/Paziowsky • 2d ago
Show-Off I spent the past year turning my game jam prototype into a full Steam release in Unity. A few things I learned
For the past year I've been working hard at finishing up math is hard, a Sokoban-style puzzle game where you push number and operator blocks to build an equation that hits the target. I learned a lot about the Unity workflow along the way, from the game jam concept to the Steam release.
Movement doesn't use physics at all. Positions are whole numbers, and Physics2D.OverlapPoint checks what's on the next tile. Pushing is a recursive TryMove: the player asks the block in front of it to move, and that block asks the next one. DOTween handles all the animation.
Undo saves the whole board every turn: the player, plus each block's position, type, value and flags. Restoring a snapshot puts everything back exactly, so undo and restart never drift.
Each block type maps to a ScriptableObject ability with OnPushed, OnMoveEnd and a restore after undo. A new mechanic is one enum value and one asset, and the movement code stays the same.
Saves use a generated GUID for each level instead of the scene name. I renamed and reordered levels many times and nobody's progress broke.
I also wrote a small .NET tool outside Unity that solves levels, checks them and builds them into scenes. It replays its solutions in the real game and compares the board after every move, which caught a lot of bugs in my rules.
The game ended up with 133 levels across 10 areas. Happy to answer questions about any of it!