Cocos2D/Box2D Endless Platformer

It’s been a long time since my last iDevBlogADay contribution. I’ve been (and still am) very busy, but wanted to share with you this code. I’m working on an endless platformer game ( and i didn’t find any tutorial or source code to help me start with the development so I’m sharing with the Cocos2D community part of my code.

I did find a tutorial from (some of my code uses snippets from this tutorial) which helped me understand how to move Box2D objects.

With this demo you will be able to:

- Create endless platforms
- Build platforms with different sizes
- Position platforms in random positions
- Assign three CCSprite to the Box2D platform (see figure 1)

The code is optimized for iPhone retina, but with some minor modifications you can make it work under iPhone & iPad screens.

If you find any bugs or can optimize the code please let me know!

Click here to download the source code.

Posted By admin

    5 Responses to “Cocos2D/Box2D Endless Platformer”

  1. [...] Cocos2D/Box2D Endless Platformer [...]

  2. Sufiyan Yasa says:

    This is great!

    Thank you.

  3. Luca says:

    Why did you stop this project?

    Let’s go on!

    For example I can add a line:


  4. admin says:

    I’ve been very busy working on my game. When I finish it I will continue updating this code if you guys think it’s useful.

  5. trizero says:

    yes! it’s very useful!! thank you

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>