One day has passed, and PewPew is doing well. It has entered the Hot android app category on AppBrain.com, and I am receiving a lot of positive feedback. While monitoring twitter I found 14n3 saying "Oh man, making a review of PewPew, this game rocks!". Always gratifying.
Unfortunately, there are a few people reporting crashes.
Since PewPew is very stable on the iOS devices, the crashes must stem from Android specific code I added. There are two areas where I am not sure I am doing everything right:
It's either the handling of the application life cycle, specifically the part where I have to reload the openGL data when the game is resumed, or the http requests to upload and download the scores and replays.
Those thing would pose no problem if PewPew was a Java application like most Android applications, but it is 99% a C++ app with a thin Java wrapper (and thus uses JNI). To reduce the amount of JNI code I cut some corners.
At first I started using the Android Java API for the http requests, but then I realised it involved doing a boatload of JNI functions and threads, so I decided to use a C++ library. Curl and Boost are the most well known C++ libraries for that kind of job, but they are also completely overkill and would require too much time to integrate in PewPew. I searched for a light alternative and found HappyHTTP.
HappyHTTP does all what I need, and can be integrated into a project simply by adding a .h and .cpp file. The only problem is that it uses C++ exceptions. I can't use exceptions in PewPew even if I wanted to, because currently the Android NDK does not support exceptions handling and STL usage at the same time! I quickly hacked an exception-free version of HappyHTTP, but I may have messed up some things up, which may cause the crashes on some devices under certain conditions...
I hope I fix everything quickly so that I can resume doing the fun stuff: working on new levels and game modes.
Hey,
ReplyDeleteLove the game, good job.
You can use an NDK compiled to use Exceptions and RTTI on Android if needs be, checkout the CrystaX.NET builds.
http://smartctl.net/android/ndk-r4.php
I don't believe there is any major downside, and you can follow the alterations they made to get yourself an NDK R5 version if you need it. Could make your life easier?
Brilliant work!!!! I have played Gun Bros,and after about 2 minutes of game play I deleted it off of my EVO 4G. Your game however has me ADDICTED. The graphics/gameplay is simply amazing. I look forward to PewPew2 for the android. Keep up the great work!!!
ReplyDeleteThis game is so frigging amazing!!! Its soo good the best game for my Android HTC Desire Z it works perfectly 0% lag and i LOVE that you can watch replays!!!!
ReplyDeleteThe only complaint is that there is some guy who is cheating the scores in all game modes and when i watch his replay he gains lik 1200 points but yet he is on top of the lists!!!
Anyway BEST GAME EVER I LOVE YOU :D
Benjamind >
ReplyDeleteThanks, I did not know about Crystax :) Now that I've managed to get everything working with the regular SDK, I am going to stay with it.
Anil Nair >
Thanks :)
Oscar >
I am working on preventing cheating !
I've been running the first edition on my Metro PCS LG M690 just fine. Love the design and game play. Maybe next edition look into the utilization of the integrated accelerometers for advanced controls of the ship.
ReplyDeleteThanks for making pewpew for android. Awsome game!!!
ReplyDeleteHow did you make the graphics in Pew Pew? Did you use Adobe Flash?
ReplyDelete