コード例 #1
0
		public static new CCEaseElasticOut actionWithAction(CCActionInterval pAction, float fPeriod)
		{
			CCEaseElasticOut cCEaseElasticOut = new CCEaseElasticOut();
			if (cCEaseElasticOut != null)
			{
				cCEaseElasticOut.initWithAction(pAction, fPeriod);
			}
			return cCEaseElasticOut;
		}
コード例 #2
0
		public override CCObject copyWithZone(CCZone pZone)
		{
			CCEaseElasticOut cCEaseElasticOut = null;
			if (pZone == null || pZone.m_pCopyObject == null)
			{
				cCEaseElasticOut = new CCEaseElasticOut();
				pZone = new CCZone(cCEaseElasticOut);
			}
			else
			{
				cCEaseElasticOut = pZone.m_pCopyObject as CCEaseElasticOut;
			}
			cCEaseElasticOut.initWithAction((CCActionInterval)this.m_pOther.copy(), this.m_fPeriod);
			return cCEaseElasticOut;
		}
コード例 #3
0
        /// <summary>
        /// creates the action
        /// </summary>
        /// <param name="pAction"></param>
        /// <returns></returns>
        public new static CCEaseElasticOut actionWithAction(CCActionInterval pAction)
        {
            CCEaseElasticOut pRet = new CCEaseElasticOut();

            if (pRet != null)
            {
                if (pRet.initWithAction(pAction))
                {
                    //pRet->autorelease();
                }
                else
                {
                    //CC_SAFE_RELEASE_NULL(pRet);
                }
            }

            return(pRet);
        }
コード例 #4
0
ファイル: CCEaseElasticOut.cs プロジェクト: liwq-net/liwq718
        /// <summary>
        /// Creates the action with the inner action and the period in radians (default is 0.3)
        /// </summary>
        /// <param name="pAction"></param>
        /// <param name="fPeriod"></param>
        /// <returns></returns>
        public static new CCEaseElasticOut actionWithAction(CCActionInterval pAction, float fPeriod)
        {
            CCEaseElasticOut pRet = new CCEaseElasticOut();

            if (pRet != null)
            {
                if (pRet.initWithAction(pAction, fPeriod))
                {
                    //pRet.autorelease();
                }
                else
                {
                    //CC_SAFE_RELEASE_NULL(pRet);
                }
            }

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

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

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

            return(pCopy);
        }
コード例 #6
0
ファイル: CCEaseElasticOut.cs プロジェクト: liwq-net/liwq718
        public override CCObject copyWithZone(CCZone pZone)
        {
            CCZone pNewZone = null;
            CCEaseElasticOut pCopy = null;

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

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

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

            var s = CCDirector.SharedDirector.WinSize;

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

            var move_ease_in = new CCEaseElasticIn((CCActionInterval) (move.Copy()));
            var move_ease_in_back = move_ease_in.Reverse();

            var move_ease_out = new CCEaseElasticOut((CCActionInterval) (move.Copy()));
            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());

            m_grossini.RunAction(new CCRepeatForever (seq1));
            m_tamara.RunAction(new CCRepeatForever (seq2));
            m_kathia.RunAction(new CCRepeatForever (seq3));
        }
コード例 #8
0
 public override CCFiniteTimeAction reverse()
 {
     return(CCEaseElasticOut.actionWithAction((CCActionInterval)m_pOther.reverse(), m_fPeriod));
 }
コード例 #9
0
 protected CCEaseElasticOut(CCEaseElasticOut easeElasticOut)
     : base(easeElasticOut)
 {
 }