Create a prototype of the Flappy Bird game for Android on LibGDX
This morning, at work, it began with a holivar on the topic of yesterday’s article : “iOS already has a physical engine, but even the camera doesn’t work normally on Android ... A customer will come, give a project to port from iOS to Android - you will evaluate it at 120 hours, and the customer will say , like so, here under iOS for 8 hours they wrote ... ". In short, I got a lot of emotions from scratch. Therefore, I decided to put some dots over the “and” (is there such a saying in Russian, or only in Ukrainian? :)). So, the task:
- write a prototype Flappy Bird using any physical engine or framework as quickly as possible.
At first I wanted to go through the source, but they turned out so primitive that I think there is no point. For development, I took the LibGDX framework and tried to write more or less beautiful code (this is an eternal topic, and each leads an ideal code in its own way).
After one and a half hours of work and half a liter of kefir, a prototype turned out. This figure does not say anything, I’m sure that there are dozens of programmers on the hub who implement this task 2-3 times faster. So by itself, if iOS developers say that they can write this in 20 minutes, I will believe it.
Conclusions:
- for Android, you can write as fast as for iOS, it all depends on the experience of the programmer;
- we got not only a prototype of the game in 90 minutes, but also a cross platform, it will work on iOS, Android, Windows / Linux / BSD / MacOS ... wherever Java is. If in the future it is planned to port to other platforms, then I think there is no need to say that it is easier to write a game from scratch than to repeat the physics in the already written one. Therefore, if you need a cross platform, it is better to immediately choose something independent.
- Yes, there are a lot of stocks in Android, there is no point in arguing which is better, Android or iOS - both have pros and cons. It is better to spend this time on family / work, besides I do not want to provoke srach in the comments.
Sources for Bitbucket (MIT license).
PS If the author of this article writes in the comments or in a personal account, how much time he spent on development - I will be very grateful.