mknutso2
mknutso2

Reputation: 47

Learning to use Cocos2D for android after iOS development

I just got done creating a game for iOS using cocos2D and am now trying to learn android development and cocos2D using eclipse. I've imported the cocos2D .jar file into the android project, but this has no nice documentation like it does programming in XCode. Could anyone provide me with a simple walkthrough on how to import the cocos2D source code into my android project so that I can view the javadoc while I write code?

I found this on a forum

---Try downloading the source files for Cocos2D and directly adding them to your project (copy the ‘org’ folder into your ‘src’ folder, then press F5 while the src folder is selected in the project explorer), making sure to remove the reference to the jar file. This should resolve any missing functionality, while giving you extra help when typing in Cocos2D code (Eclipse will automatically display the javadoc comments for you).---

I assume this is the source code: https://github.com/ZhouWeikuan/cocos2d/tree/master/cocos2d-android but I don't see any org folder, and would greatly appreciate a better walkthrough in general.

Could anybody help? I would really like to have the javadoc to help me through the learning curve.

P.S. I'm new to the forum, and maybe this should be a new question of itself, but the .jar file I'm currently using I downloaded from http://code.google.com/p/cocos2d-android-1/downloads/detail?name=cocos2d-android.jar&can=2&q= but I seem to be missing some implementation such as CGRectIntersectsRect and CCTMXTiledMap. Is this an outdated .jar that not up to date and something that would be fixed using the source code? I have seen examples of both used for android so I know they are implemented in some revision of cocos2d for android.

Any help or advice would be greatly appreciated.

Upvotes: 1

Views: 1978

Answers (1)

Jimmar
Jimmar

Reputation: 4449

the org folder you are talking about is included in here https://github.com/ZhouWeikuan/cocos2d/tree/master/cocos2d-android/src

download the whole project then just copy the org folder to your src folder in eclipse this is a nice tutorial for starting http://dan.clarke.name/2011/04/how-to-make-a-simple-android-game-with-cocos2d/

it's a good thing to do so you can figure out the small differences between the cocos2d-iphone and cocos2d-android , just following the first tutorial should do it for you

Upvotes: 1

Related Questions