码迷,mamicode.com
首页 > 其他好文 > 详细

cocos2dx2.2.3重要学习笔记

时间:2014-12-23 19:29:14      阅读:188      评论:0      收藏:0      [点我收藏+]

标签:

(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)); 

(2)
 pStar1->runActionDelay(1.2f,CCRepeatForever::create(CCSequence::createWithTwoActions(
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)));

(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); 
等价成
pLabelView->runAction(CCDelayTime::create(timeDelay));
pLabelView->runAction(CCSequence::create(
CCShow::create(),
CCMoveTo::create(0.5f + time, ptEnd),
CCCallFuncO::create(this, callfuncO_selector(GameLayer::onAddPoint), CCInteger::create(stepValue)),
NULL));

(4)

cocos2dx2.2.3重要学习笔记

标签:

原文地址:http://blog.csdn.net/wxq_wuxingquan/article/details/42106161

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!