コード例 #1
0
ファイル: CCEaseOut.cs プロジェクト: chengcong/cocos2d-xna
        public static new CCEaseOut actionWithAction(CCActionInterval pAction, float fRate)
        {
            CCEaseOut cCEaseOut = new CCEaseOut();

            if (cCEaseOut != null)
            {
                cCEaseOut.initWithAction(pAction, fRate);
            }
            return(cCEaseOut);
        }
コード例 #2
0
        /// <summary>
        /// Creates the action with the inner action and the rate parameter
        /// </summary>
        /// <param name="pAction"></param>
        /// <param name="fRate"></param>
        /// <returns></returns>
        public new static CCEaseOut actionWithAction(CCActionInterval pAction, float fRate)
        {
            CCEaseOut pRet = new CCEaseOut();

            if (pRet != null)
            {
                if (pRet.initWithAction(pAction, fRate))
                {
                }
                else
                {
                }
            }

            return(pRet);
        }
コード例 #3
0
ファイル: CCEaseOut.cs プロジェクト: chengcong/cocos2d-xna
        public override CCObject copyWithZone(CCZone pZone)
        {
            CCEaseOut cCEaseOut = null;

            if (pZone == null || pZone.m_pCopyObject == null)
            {
                cCEaseOut = new CCEaseOut();
                pZone     = new CCZone(cCEaseOut);
            }
            else
            {
                cCEaseOut = (CCEaseOut)pZone.m_pCopyObject;
            }
            cCEaseOut.initWithAction((CCActionInterval)this.m_pOther.copy(), this.m_fRate);
            return(cCEaseOut);
        }
コード例 #4
0
        /// <summary>
        /// Creates the action with the inner action and the rate parameter
        /// </summary>
        /// <param name="pAction"></param>
        /// <param name="fRate"></param>
        /// <returns></returns>
        public new static CCEaseOut actionWithAction(CCActionInterval pAction, float fRate)
        {
            CCEaseOut pRet = new CCEaseOut();

            if (pRet != null)
            {
                if (pRet.initWithAction(pAction, fRate))
                {

                }
                else
                {

                }
            }

            return pRet;
        }
コード例 #5
0
ファイル: CCEaseOut.cs プロジェクト: homocury/cocos2d-xna
        public override object Copy(ICopyable pZone)
        {
            CCEaseOut pCopy;

            if (pZone != null)
            {
                //in case of being called at sub class
                pCopy = (CCEaseOut) (pZone);
            }
            else
            {
                pCopy = new CCEaseOut();
            }

            pCopy.InitWithAction((CCActionInterval) (m_pOther.Copy()), m_fRate);

            return pCopy;
        }
コード例 #6
0
        public override CCObject copyWithZone(CCZone pZone)
        {
            CCZone pNewZone = null;
            CCEaseOut pCopy = null;

            if (pZone != null && pZone.m_pCopyObject != null)
            {
                //in case of being called at sub class
                pCopy = (CCEaseOut)(pZone.m_pCopyObject);
            }
            else
            {
                pCopy = new CCEaseOut();
                pZone = pNewZone = new CCZone(pCopy);
            }

            pCopy.initWithAction((CCActionInterval)(m_pOther.copy()), m_fRate);

            return pCopy;
        }
コード例 #7
0
        public override CCObject copyWithZone(CCZone pZone)
        {
            CCZone    pNewZone = null;
            CCEaseOut pCopy    = null;

            if (pZone != null && pZone.m_pCopyObject != null)
            {
                //in case of being called at sub class
                pCopy = (CCEaseOut)(pZone.m_pCopyObject);
            }
            else
            {
                pCopy = new CCEaseOut();
                pZone = pNewZone = new CCZone(pCopy);
            }

            pCopy.initWithAction((CCActionInterval)(m_pOther.copy()), m_fRate);

            return(pCopy);
        }
コード例 #8
0
        public override void OnEnter()
        {
            base.OnEnter();

            var size = CCDirector.SharedDirector.WinSize;

            var move = new CCMoveBy (3, new CCPoint(size.Width - 130, 0));
            var move_back = (CCActionInterval) move.Reverse();

            var move_ease_in = new CCEaseIn((CCActionInterval) move.Copy(), 2.5f);
            var move_ease_in_back = move_ease_in.Reverse();

            var move_ease_out = new CCEaseOut((CCActionInterval) move.Copy(), 2.5f);
            var move_ease_out_back = move_ease_out.Reverse();

            var delay = new CCDelayTime (0.25f);

            var seq1 = CCSequence.FromActions(move, delay, move_back, (CCFiniteTimeAction) delay.Copy());
            var seq2 = CCSequence.FromActions(move_ease_in, (CCFiniteTimeAction) delay.Copy(), move_ease_in_back, (CCFiniteTimeAction) delay.Copy());
            var seq3 = CCSequence.FromActions(move_ease_out, (CCFiniteTimeAction) delay.Copy(), move_ease_out_back,
                                                (CCFiniteTimeAction) delay.Copy());

            var a2 = m_grossini.RunAction(new CCRepeatForever ((CCActionInterval)seq1));
            a2.Tag = 1;

            var a1 = m_tamara.RunAction(new CCRepeatForever ((CCActionInterval)seq2));
            a1.Tag = 1;

            var a = m_kathia.RunAction(new CCRepeatForever ((CCActionInterval)seq3));
            a.Tag = 1;

            Schedule(testStopAction, 6.25f);
        }
コード例 #9
0
 public virtual CCActionInterval easeActionWithAction(CCActionInterval action)
 {
     return(CCEaseOut.actionWithAction(action, 2.0f));
 }
コード例 #10
0
ファイル: CCEaseOut.cs プロジェクト: homocury/cocos2d-xna
 public static new CCEaseOut Create(CCActionInterval pAction, float fRate)
 {
     var pRet = new CCEaseOut();
     pRet.InitWithAction(pAction, fRate);
     return pRet;
 }
コード例 #11
0
ファイル: CCEaseOut.cs プロジェクト: HarkDev/cocos2d-xna
 public CCEaseOut(CCEaseOut easeOut)
     : base(easeOut)
 {
 }
コード例 #12
0
 public CCFiniteTimeAction easeActionWithAction(CCActionInterval action)
 {
     return(CCEaseOut.actionWithAction(action, 2f));
 }