Social Icons

Pages

Featured Posts

Monday, January 7, 2013

Porting RPG Maker games on Android - part 1

Welcome to my tutorial series, in this first installment ill try to give a brief overall overview of the project and its objectivesand help others porting their game to the android platfom, and really any device that supports native compiling (iphone, android, bada, windows phone 8... more on that on the next part). But first things first, I know a lot of you want to test ASAP what has been done as of today.



Source Code and tools First, point your SVN tool (for example, TortoiseSVN) to this location: http://rm20xx-android.googlecode.com/svn/trunk/ and checkout project files. This project uses vs-android for fast compiling/syntax sugar and debugging for native android. With that said you will need Visual Studio (I use visual studio 2010, havent tested with express), vs-android ( get the last version here: http://code.google.com/p/vs-android/ and install after you have installed Visual Studio). So here is a review of the tools needed:

Visual Studio 2010

VS-android and dependencies(if im not mistaken ANT) http://code.google.com/p/vs-android/ 0.94 and up

Download and install last Android SDK from (http://developer.android.com/sdk/index.html).

Download and install last NDK from (http://developer.android.com/tools/sdk/ndk/index.html).

Compiling and Testing

Lets say we have checked out the source to C:\wcrm20xx, just open visual studio file located at: C:\wcrm20xx\wcrm20xx.sln and if you have everything installed correctly just plug your android device and press the build Button, the engine will be built and deployed to your device automatically, depending on vsandroid version you might need tweak settings for autodeploying. Anyway binaries should have been built at C:\wcrm20xx\AndroidApk\bin\wcrm20xx-debug.apk, so if it fails deploying or installing for whatever reason just copy those to your sdcard. More on release packaging(necessary for market) on the next part. but just keep in mind that release is very simple and if you have some familiarity with eclipse just import the project to eclipse and sign the apk from there. For further informations about packaing release binaries from Visual Studios check the next installments on these series.

Now if you want to test you own game, just copy and paste your rpg maker files to folder (C:\wcrm20xx\AndroidApk\assets), _do not delete anything_, just replace any graphic file if asked do not copy RPG_RT.exe. Now, I have to say, it wont work out of the box just because the way opengl works and the engine is coded right now. You will need to convert manually your image files to the next power of two possible size, and apply alpha manually. This is the main reason the engine isnt production ready right now, there is a lot of manual work involed still. More on this in the next section.

After that just rebuild the project and run again.

Shortcomings

As mentioned earlier, due to the opengl nature, and lack of SDL porting for now there is some manual work to do. Sure there are some tools to automate this process (imagemagick ,etc) but the ultimate goal of this project is to have it all automated, ie: copy paste,buld apk and profit =)

TODO

  • Make building process as automated as possible, this might involve porting SDL and using on the project just for color keying and image resizing.
  • Port to other plataforms. iphone, android, bada, windows phone 8...
  • Update project to use surfaceview instead of current, will boost perfomance and resolve some perfomance issues.
  • Update to OpenglES, which gives access to GLSL and more.
  • Update the project to lastest wolfcoder codebase
  • Make Bugs.
  • Fix bugs :)
Next parts
  • Under the hood (information about my OpenglES Engine that is the core to this project)


Donations

If you like my work and want to help please consider making a donation: ill use the money to buy a idevice, and more importantly make the improvements listed on the TODO. As a form of incentive im willing to help donators in a more personal way, if you make a contribution please highlight in the contribution comment which feature you think its more important for you, and ill prioritize it, besides that ill be available at skype: valdir.salgueiro3 and gtalk: valdir(dot)salgueiro(at)gmail(dot)com for project specific stuff. make sure to send questions there for faster responses since i cant constantly check forums.



any help regarding source contribution is also very welcomed.

Credits

WolfCoder for the base of this project.