Reputation: 2136
I am new to Cocos 2D, I have studied cocos 2D framework and after two days i am just confused and wanted to ask you some question.
I have to create an app with cocos2D framework for both iPhone and iPad target.
Upvotes: 0
Views: 178
Reputation: 191
According to me answer to your question is
1- Use Box2d only if you want to simulate some thing like real world.Gravity, mass, natural collision other wise simple 2d games can be made only using cocos2d.Box2d is for much real world simulation.
2-As far as I know there is no Nib files in cocos2d but we use CCLayer instead.All visible content of game is arranged on CCLayer or child of it.There is not any thing like Interface builder but we use coding for CCSprite,CCMenu,etc.
3-For creating app for i phone as well as i pad use universal build in device family on Info page of application.Use different resource for different device and do coding something like
if(UI_USER_INTERFACE_IDIOM()==UIUserInterfaceIdiomPad)
{
CCSprite *back=[CCSprite spriteWithFile@"back-ipad.png"];
// rest of coding
}
else
{
CCSprite *back=[CCSprite spriteWithFile@"back-.png"];
// rest of coding
}
Upvotes: 0