Search code examples
ipadios4cocos2d-iphoneuniversal

How to make Cocod2d 0.99.4 game universal(iOS4+iOS3.2+iOS<3.2) in iPhone SDK 4.1. I am stucked


when i create a cocos2d projecyt, XCode menu item "Project\Upgrade Current Target for iPad" becomes disable. Any solution please?

EDITED:

  • I am using SDK 4.1 and cocos2d 0.99.4 for iPhone.
  • When I create iOS native application i get options to select target device (iPhone/iPad).
  • But with cocos2d, there is no option. Though iphone apps can be run on iPad changing the target iOS, but it keeps its iPhone resulation(screen size).

Solution

  • Sadat, you'll have to go into either your Project of Target Settings and change the targeted device, like the first step of this tutorial shows. I find that it's helpful sometimes to create a template project, upgrade to universal and compare settings between the cocos2d project and the test iPhone project. (Make sure to compare info.plist files as well.) Really, once you change the settings to be the same, you'll have done all of the work that the option would have anyway. Nothing special, just some automation.

    Once you do this, as long as you're initializing cocos2d correctly, you should be able to select "iPad Simulator 3.2" from the dropdown as suggested, and be up and running.