cocos2d-x中类似于齿轮旋转,定时旋转,无限旋转

        //齿轮
        UIImageView *login_ent_bg=dynamic_cast(pUILayer->getWidgetByName("login_ent_bg"));
        CC_BREAK_IF(!login_ent_bg);
        
        login_ent_bg->setVisible(true);

        
        
       // auto act =CCRepeatForever::create(CCSequence::create(CCScaleTo::create(55555,1.01,1.2),CCScaleTo::create(5555,1,1.4),NULL));
        
        //auto act_goto =CCRepeatForever::create(CCSequence::create(CCScaleBy::create(.5,1.01),CCScaleBy::create(.15,1),NULL));
        
        //login_ent_bg->runAction(act);
        
        
        
       
   
         //CCActionInterval *forwardTo=CCRotateTo::create(100, 7000);      //100秒旋转7000度
       //  login_ent_bg->runAction(forwardTo);

        
        //旋转
        //  CCRotateTo*scaleTo=CCRotateTo::create(1000.0f,18000.0f);   //100秒旋转7000度

        
       
    //    login_ent_bg->runAction(scaleTo);
      
        
  
        
        
            //无限循环旋转
            login_ent_bg->runAction(CCRepeatForever::create(CCRotateBy::create(1.0f, 35.0f)));

你可能感兴趣的:(cocos2dx,C/C++)