So I kicked the project going and started to type. There’s some excellent tutorials about how you create your project, for example here: (http://developer.android.com/training/basics/firstapp/index.html)
Since this was my first Android application ever, first I need to draw something on the screen. Because I am trying to create a game I wanted to draw something to the Canvas. By reading the API it was pretty easy to find what to methods to call. The real problem was just how would I be able to see it on the device. I thought initially that virtual device would be the answer and it is of course to some extent. But starting the emulator is FREAKIN’ SLOW. The first run when emulator created all stuff it needs, it can take several minutes.
I was put down by the time it took to run the small piece I wrote. It would really take ages if I would have to wait minutes just to kick the emulator running. Luckily the first time is the slowest and it gets faster. Moreover, you don’t need to exit the emulator, just redeploy and it is faster. I also read somewhere that using “the host GPU” setting in “AVD Manager” can make a lot difference. I turned that on and it was now at acceptable level, slow but acceptable.
What I spent next (many) hours was trying to produce simple things on the screen like text, shapes, color etc. so I would know what and how to draw things. Next step was to create classes responsible for different things, like GameButton, Menu etc. I drew some ugly placeholder graphics with Paint (yeah, the default “drawing tool” for Windows !!) so I could just see some of the graphics in action and more over I needed measurements of the images (width, height) so I could check it something had been pressed.
The more I wrote, the more aware I became that I was not going to be satisfied by only if I get the game done. I wanted more. I created a list of features that my game needs to have. Initially my list was something like this:
- Create different difficulty settings
- Add different game modes (if possible)
- Add high scores
- Add Google Ads (if possible)
- Add sounds to game events
I also have a tendency of doing things so whatever feature I work on, I get it first just barely working and then I later polish and tune it better. This applies to code, but also now to the graphics and placing of elements to the screen.
This is what I have currently, it’s the game main screen with few letters and a score panel. Letters are drawn as separate objects defined by a word (currently static). Letters are images that are created at the runtime. That means that I don’t have an image for every letter in my assets folder.
I have actually a menu before this but it’s just a screen with “play”, “settings” and “other” menu items. Now I just need more functionality and it comes only by typing!