Megaball
Megaball is inspired by MegaBall on the Amiga. It is a breakout-style game and features 20 challenging boards, 9 upgrades and a high score system. Some of the upgrades: Brickthrough, Catch, Quicksand and Lasers. The game is written in Z80 Assembler for the TI-83/84+ graphing calculator.



MegaBall on the Amiga was always one of my favorite games. The game was fast-paced and had great graphics and sound effects. The game included a level editor, which was fun to use. The objective of the game is to clear boards of bricks by releasing and bouncing around a ball. Once the ball collides with a brick, the brick disappears from the board, unless it is a special type of brick. The player controls a paddle that can interact with the ball. When the player has cleared all of the bricks from the board, the next board can be loaded.
Development
I wanted Megaball to capture the essence of the original game. Although the screen of the TI-83 is very small, I still wanted the game to look like the original. The game had to be fast-paced, just like the original.
Before creating any code, I started with the graphical assets of the game. Below you can see the sprites that are used in the game. On the left of the image, you can see the sprites that are used to create the paddle. The paddle can be dynamically changed, based on power-ups and the state of the game. The paddle can be increased in length or shortened, the paddle can fire lasers and the paddle can catch the ball using a magnetic field. In the upper-right corner of the image, you can see the power-ups. The lower-right corner shows the types of bricks that are available and the ball.
I have implemented the following power-ups, as represented in the image above:
- Extra Life
- Brickthrough
- Catch
- Quicksand
- Lasers
- Dietpill
- Kill
- Expand
- Zap
The following brick types are available:
- Normal
- Bomb
- Multistate
- Gold
- Hidden
To create the boards, I made a simple level editor. Below you can see how the level editor looks like. It was written using Borland Delphi. The boards would get compressed with another program and exported to assembly code. The image of the editor shows the first board, as can be seen in the second screenshot at the top of this page.
Once a calculator game is ready to be released, it needs to be assembled by TASM. The resulting code is handed over to a packer/linker program, such as Devpac83, to make the program runnable by a calculator. I decided to write my own program, Cryptpac83, to allow my final code to have a form of encryption. If you open the game with a hex editor, you would see: “This file is mangled by Cryptpac83!”, but opening the game with a disassembler would not reveal the code and data. Cryptpac83 tries to find a user-inserted signature in the object code of the game. If it finds the signature, the program replaces it with a decryptor routine and mangles the rest of the object code. Before the game starts on the calculator, the decryptor runs and makes the game runnable. When the game exits, the game is encrypted again, including stored variables, such as high scores and savegames.
Download
Megaball TI-83 (Ion)
Megaball TI-83/84 Plus (Ion)