Flood Wars



I had a similar game on my Windows Mobile PDA. When I later started using Android, I was disappointed there weren't any good-looking versions of the game. So I decided to make my own.


Implementation Details

In 2013 when I weas developing the game, downscaling bitmaps using standard Android tools produced mediocre results. I didn't want to sacrifice visual quality of my game, so I decided to draw all bitmaps at their native resolution. At the same time, I wanted the game to be compatible with as wide range of resolutions (including future resolutions) as possible. In order to achieve this, I created a simple 3 by 3 transparent PNG "spritemap" with all the bitmap masks my game needed. One for the button and eight for the different tile styles. I then included 66 versions of this spritemap in my game. The spritemaps were sized in such a way that each button/tile version would differ in size by only one pixel.

9 tiles arranged in a square grid

I wouldn't do something like this today. But with the low resolution screens and Android limitation in 2013 I believe this was justified. In the end this approach didn't have significant impact on the game's size, as the game is just under 2 megabytes.