Inspiration
This was honestly one of my favourite hackathon projects to work on. I love tower defense games, but my first idea felt too generic. It was the usual setup of enemies moving across the screen while towers attacked them.
I then tried making an arcade management game and added a small pinball machine to it. That’s when the idea hit me. What if the pinball machine itself was the tower defense game?
The enemies could be balls falling towards the drain, while the player placed paddles and bumpers to knock them back, damage them, and make them collide. That idea became MEGABALL.
What it does
MEGABALL combines tower defense strategy with pinball physics. Players place and upgrade paddles and bumpers, manage their Energy, use power cards, and control the two flippers at the bottom of the table.
The game includes five campaign levels, different enemy types and bosses, star-based unlocks, and an Endless Mode that becomes harder with every wave.
My favourite mechanic is the Mega Ball. The Mega Ball card and Power Paddle turn an enemy ball into a weapon. When it hits other balls, it destroys them and can start a chain reaction across the table.
How we built it
I started with a Markdown design document to work out the main mechanics before building the prototype.
The game uses a custom physics system for the balls, bumpers, paddles, rails, and flippers. The machine is rendered in 3D, with the balls, effects, and interface layered over it.
I used Claude Code throughout development and OpenAI Codex for image generation. The sound effects are generated in code, and the game is packaged to run completely offline.
Challenges we ran into
The physics caused some of the biggest problems. Balls could become trapped between parts of the table or bounce in the same place forever. I redesigned parts of the board and added systems to detect and free stuck balls.
Touch controls were also difficult. Tapping the playfield controls the flippers, but players also need to open defense upgrades. This caused accidental inputs, so tapping now operates the flippers while holding on a defense opens its upgrade panel.
The tutorial uses the real game physics, which created some funny issues. At one point, a ball landed perfectly on a peg and stayed balanced there. Every tutorial step had to be carefully positioned and tested.
Accomplishments that we're proud of
I’m proud that the game feels like more than a standard tower defense game with a different visual theme. Pinball physics actually changes how the player positions defenses and reacts during each wave.
I’m also proud of the Mega Ball chain reactions, the interactive tutorial, the different bosses, and getting the whole game working offline across different portrait screen sizes.
What we learned
I learned that making a feature work is only the first step. It also needs to be clear, responsive, and satisfying when someone actually plays it.
I also learned that restrictions can lead to better ideas. The portrait and offline requirements felt limiting at first, but they pushed me towards the concept that made MEGABALL feel different.
What's next for MEGABALL - Pinball Tower Defense
I’d like to add more worlds, bosses, cards, random events, and higher upgrade tiers such as Mega Ball I, II, and III.
I also want players to merge two Level I defenses into a stronger Level II version, add more player-controlled side paddles, and improve the game feel with more sound effects, haptics, and bigger chain reactions.
Built With
- ai-generated
- art
- audio
- canvas
- claude
- codex
- html5
- javascript
- mobile
- offline
- procedural
- three.js
- web

Log in or sign up for Devpost to join the conversation.