【Cocos学习】平时技术点积累

来源:互联网 发布:pdf编辑软件手机 编辑:程序博客网 时间:2024/06/09 07:19

1、粒子效果

CCParticleSystem*sp = CCParticleSnow::create();

sp->setTexture(CCTextureCache::sharedTextureCache()->addImage("f.png"));

this->addChild(sp);

2、Plist文件

CCSpriteFrameCache::sharedSpriteFrameCache()->addSpriteFramesWithFile("all.plist"); 

cannon = CCSprite::createWithSpriteFrameName(cannonPath); 

0 0
原创粉丝点击