Quantcast
Channel: Scratch Where It's Itching
Viewing all articles
Browse latest Browse all 73

Dobutsu on Android

$
0
0
Some time ago, I developped a Dobutsu game in Java. Dobutsu is the initiation game for Shogi, the Japanese chess. It is mainly used for teaching kids some of the basics of the game, although it was invented by a woman Shogi master to draw more women to the game.

Since I bought my smartphone, I had the idea of porting this game to Android. The language is still java, and although it is not Swing, the API looks similar enough with widgets, layouts, listeners and so on. The only thing that retained me was the first step: installing the Eclipse plugin on my family computer was something that I kept postponing.

Until I discovered AIDE, an IDE for Android. This was a real breakthrough: a text editor capable of syntax highlighting, code completion, code formatting, incremental compilation and much more, all on my phone! I remember a guy at Devoxx saying that smartphones are eight times more powerful than the computer that first sent a man into space. I should be able to develop a small game with it. And that is what I did, and had a lot of fun on my comuter train.

The porting was not really hard. I only used the tutorial on the Android Developer's site. I had one difficulty with transposing from logical to physical coordinates. I tried what seemed logical for me, but it did not work. Eventually, I asked for help from a colleague (thanks JB alias twister) who solved it using the Matrix class.

And finally, here it is: Dobutsu for Android. Enjoy!


Viewing all articles
Browse latest Browse all 73

Trending Articles