(1) runActionDelay(1,CCFadeOut::create(CCRANDOM_0_1()*0.3f+0.2f));比如这个
等价成:
CCDelayTime*delayAction=CCDelayTime::create(1);
CCFadeOut*outAction=CCFadeOut::create(CCRANDOM_0_1()*0.3f+0.2f);
pStar1->runAction(CCSequence::create(delayAction,outAction,NULL));
pStar1->runAction(CCSequence::create(delayAction,outAction,NULL));
pStar1->runActionDelay(1.2f,CCRepeatForever::create(CCSequence::createWithTwoActions(
CCFadeIn::create(1.0f),CCFadeOut::create(1.5f))));
CCFadeIn::create(1.0f),CCFadeOut::create(1.5f))));
等价成
pStar1->runAction(CCDelayTime::create(1.2f));
pStar1->runAction(CCRepeatForever::create(CCSequence::createWithTwoActions(
CCFadeIn::create(1.0f),CCFadeOut::create(1.5f)));
pStar1->runAction(CCRepeatForever::create(CCSequence::createWithTwoActions(
CCFadeIn::create(1.0f),CCFadeOut::create(1.5f)));
(3)
pLabelView->runActionDelay(timeDelay,CCSequence::create(
CCShow::create(),
CCMoveto::create(0.5f+time,ptEnd),
CCCallFuncO::create(this,callfuncO_selector(GameLayer::onAddPoint),CCInteger::create(stepValue)),
NULL),true);
CCShow::create(),
CCMoveto::create(0.5f+time,ptEnd),
CCCallFuncO::create(this,callfuncO_selector(GameLayer::onAddPoint),CCInteger::create(stepValue)),
NULL),true);
等价成
pLabelView->runAction(CCDelayTime::create(timeDelay));
pLabelView->runAction(CCSequence::create(
CCShow::create(),
CCMoveto::create(0.5f + time,
CCCallFuncO::create(this,
NULL));
pLabelView->runAction(CCSequence::create(
CCShow::create(),
CCMoveto::create(0.5f + time,
CCCallFuncO::create(this,
NULL));
(4)
Cocos新手学习必备源码啊,大量本人写的的源码(有些商业的淘宝店木有放出来,可以私聊),ARPG,动作射击,闯关益智,可学习可运营 个人淘宝店,适合新手,我还可以做技术支持,帮助换皮,带新手等https://shop141567464.taobao.com/?spm=a313o.7775905.1998679131.d0011.pzUIU4
不懂的可以加我的QQ群: 239982941(cocos2d-x 3.x学习群)欢迎你的到来哦,看了博文给点脚印呗,谢谢啦~~