Cocos2D is a popular open source framework for building iPhone games. Its quite powerful and can be used to develop a wide range of 2D games. Here is a list of some of the apps on the appstore developed using Cocos2D.
This blog describes how to develop realtime multiplayer games using Cocos2D by integrating with the AppWarp apis. AppWarp is a new cloud framework which allows you to develop cross-platform realtime multiplayer games by taking care of all the networking, routing and messaging between players. You can get an overview of AppWarp here.
There are many tutorials on how to use Cocos2D – one great one can be found here.
The best way to get started on making your first realtime multiplayer Cocos2D game is to download the sample project code from our git repo here. Its a simple soccer ball kicking application which illustrates the realtime multiplayer aspect integrated in to Cocos2D. Follow the 5 simple steps in the README file to quickly get up and running.
Here is a screenshot of how it should look once setup.
Enter your name in the first screen and hit ‘start’. Now run the app on another simulator or device and enter a different name and hit ‘start’.
Both the devices should see the following screen at this time. Start tapping on the screen and see the balls flying from both the devices/simulators!
The high-level operation performed in this example are
1. Initialize the AppWarp SDK with your keys
2. Connect and JoinZone with the name entered.
3. Subscribe and Join the room you created.
4. Use the SendUpdatePeers api and OnUpdatePeersReceived event to do the magic.
Interested in learning more about AppWarp?
Visit our iOS developer guide.
Integrate cloud Leader board apis in your game
Please try this out and share your feedback with us on email@example.com