Kotori your flying friend!

September 2016 ยท 3 minute read

Some years ago I released the “Kotori Live Wallpaper” on Google Play. At the time called Android Market. The idea behind Kotori was to treat your background on your Android phone with a little Tamagotchi experience. Kotori is a little bird that “lives” on your phone. You need to feed and bath Kotori. Kotori in turn gives you small quotes and ideas; in the form of text on screen. Simulating that Kotori is aware of you and your phone. Your phone is low on battery? Sure enough Kotori will let you know. All kinds of reactions to the behaviors of your phone.

It had its success. First launched as a paid app, later a free version came. All-in-all Kotori Live Wallpaper achieved ~100.000 installs. Paid 5% and 95% for the free version.

Now I have almost finished a new implementation. The old version was implemented using the Canvas-class and bitmap manipulation. It was a very slow rendering method. Not accelerated by a GPU. Rendered at 1 FPS. Similar to the original Tamagochi experience. The new implementation uses libGDX for the drawing and rendering part. With libGDX all rendering is done wrapped through OpenGL ES 2.0. This means GPU-acceleration. Currently this new version as no limit on FPS rendered. This gives a smoother experience. Sprite animations are used for the different animations of Kotori. All the sprites are reused from the old implementation. These were all handdrawn on paper with a graphite pencil and then scanned digitally.

The core logic of Kotori is represented in something very similar to a finite state machine. Kotori lives its life in states. Even if you have your device turned off Kotori will still live on. When you turn your device screen off a timestamp is persisted. When you turn on your device again the difference in time is calculated and added to the simulation. Thus the life of Kotori continues even when your device is off in some sense.

The new version is scheduled to launch the 25th of September on Google Play. There is a trial period of 24 hours. Hereafter you can unlock with a payment of .75 dollars. I’m using the In-app Billing service on Android from Google. This is a first for me using this service. We’ll see how it goes. To make things even simpler I’m using this wrapper; https://github.com/anjlab/android-inapp-billing-v3. I discovered some inconsistencies with documentation on how to test In-app Billing. Google provides some SKUs that will return some static responses. These SKUs provided by Google will not have a valid signature though. The opposit is stated in the documentation. This means you can’t actually see a purchase the whole way through.

I really like libGDX. Everything is wrapped intelligently and the documentation is pretty up-front. Some inconsistency but that is always expected in some form. What I really like about libGDX is that it makes it possible to target other platforms without much tailoring. I’m not sure Kotori will see other platforms though. The experience is too centered around the Android device.

I invite you to try out the new version of Kotori. Hopefully it can bring you some smiles. If you like the idea behind the Tamagotchi I think you’ll find Kotori to be a fun little exprience. Please try out Kotori your friend! on Google Play! Have fun!