Go Multi-Platform with Cocos2d JS
Cocos2d-iphone has proven to be a great platform for creating iOS games, with many titles hitting the top of the charts in the AppStore. The introduction of cocos2d-x made it possible to write C++ games that ran on many devices, including iOS, Android and as applications on stationary computers. The next big thing in the Cocos2d universe is the release of Cocos2d JS! Cocos2d JS makes it possible to write your code just once and have run in all major web-browsers through HTML5 and with close to native performance on iOS and Android devices.
At Zynga, Cocos2d JS is already being used to create a set of new game titles. Cocos2d-iphone and CocosBuilder – the graphical tool that goes with Cocos2d – are open sourced by Zynga.
How it Works
Having your game code in a scripting language provides more advantages than just the cross-platform aspect. As the code is not compiled, it can be replaced in run-time which allows much faster testing cycles.
CocosBuilder and CocosPlayer
One issue when making a game run on multiple platforms is that different platforms require different sets of resources. For instance, an iPhone may need different sets of graphics depending on if it has retina display or not and sounds may need to be saved in different formats for optimal playback. CocosBuilder makes this easy by automatically converting between resolutions and formats. It can even make different sprite sheets from a single set of images. If the automated resizing is not good enough for some of your sprites, you can always provide scaled images yourself for the different devices. It is as easy as dropping a file in a folder.