Hello. I’m wonder if there is a correct way to load sprite or images from zip archive?
For now i’m thinking to pass the data over the texture.
CCTexture2D * texture = new CCTexture2D();
const char * tdata = CCFileUtils::getFileDataFromZip(resname, imagename, &pSize);
texture->initWithData(tdata, CCTexture2DPixelFormat, width, height, CCSizeMake(width, height));
CCSprite * sprite = CCSprite::spriteWithTexture(texture);
But it seems to be a little confusing. Is there a more beautiful solution?