I have a problem following a tutorial for cocos2d 3.0 in cocos2d 3.1 ... when compilation finish show a warning "CCSpriteBatchNode is deprecated", how can I use the plist now? or isn't used now in cocos2d 3.1? can you write an example, would very helpful :)
@implementation GameScene
{
CCSpriteBatchNode *_batchNode; // WARNING 1 HERE
Hunter *_hunter;
Bird *_bird;
}
-(void)addBackground
{
//1
CGSize viewSize = [CCDirector sharedDirector].viewSize;
//2
CCSprite *background = [CCSprite spriteWithImageNamed:@"game_scene_bg.png"];
//3
background.position = ccp(viewSize.width * 0.5f, viewSize.height * 0.5f);
//4
[self addChild:background];
}
-(void)createBatchNode {
//1
[[CCSpriteFrameCache sharedSpriteFrameCache] addSpriteFramesWithFile:@"Cocohunt.plist"];
//2
_batchNode = [CCSpriteBatchNode batchNodeWithFile:@"Cocohunt.png"]; // WARNING 2 HERE
//3
[self addChild:_batchNode z:1];
}