cocos2d 间隔动作

CCSize size=CCDirector::sharedDirector()->getWinSize(); 
    CCSprite* spr1=CCSprite::create("s_2.png");
    spr1->setPosition(ccp(size.width*0.2,size.height*0.2));
    this->addChild(spr1);

    CCActionInterval* action=CCMoveTo::create(3.0f,ccp(size.width*0.8,size.height*0.8));
    //spr1->runAction(action);
    CCActionInterval* action2=CCJumpTo::create(3.0f,ccp(size.width*0.8,size.height*0.8),100,1);
    //spr1->runAction(action2);
    CCActionInterval* action3=CCScaleTo::create(3.0f,2.0,2.0);
    //spr1->runAction(action3);
    CCActionInterval* action4=CCRotateTo::create(3.0f,720);    
    //spr1->runAction(action4);
    CCActionInterval* action5=CCSkewTo::create(3.0f,10,10);    
    //spr1->runAction(action5);
    CCActionInterval* action6=CCBlink::create(3.0f,10);    
    //spr1->runAction(action6);
    CCActionInterval* action7=CCFadeIn::create(3.0f);    
    //spr1->runAction(action7);
    CCActionInterval* action8=CCFadeOut::create(3.0f);    
    //spr1->runAction(action8);
    CCActionInterval* action9=CCFadeTo::create(3.0f,100);    
    //spr1->runAction(action9);
    CCActionInterval* action10=CCTintTo::create(3.0f,255,0,0);    
    spr1->runAction(action10);

 

posted @ 2014-03-21 23:12  yufenghou  阅读(329)  评论(0编辑  收藏  举报