/// <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 new static CCEaseElasticInOut actionWithAction(CCActionInterval pAction, float fPeriod) { CCEaseElasticInOut pRet = new CCEaseElasticInOut(); if (pRet != null) { if (pRet.initWithAction(pAction, fPeriod)) { //pRet->autorelease(); } else { //CC_SAFE_RELEASE_NULL(pRet); } } return(pRet); }
/// <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 CCEaseElasticInOut actionWithAction(CCActionInterval pAction, float fPeriod) { CCEaseElasticInOut pRet = new CCEaseElasticInOut(); if (pRet != null) { if (pRet.initWithAction(pAction, fPeriod)) { //pRet->autorelease(); } else { //CC_SAFE_RELEASE_NULL(pRet); } } return pRet; }
public override CCObject copyWithZone(CCZone pZone) { CCZone pNewZone = null; CCEaseElasticInOut pCopy = null; if (pZone != null && pZone.m_pCopyObject != null) { //in case of being called at sub class pCopy = pZone.m_pCopyObject as CCEaseElasticInOut; } else { pCopy = new CCEaseElasticInOut(); pZone = pNewZone = new CCZone(pCopy); } pCopy.initWithAction((CCActionInterval)(m_pOther.copy()), m_fPeriod); return(pCopy); }
public override CCObject copyWithZone(CCZone pZone) { CCZone pNewZone = null; CCEaseElasticInOut pCopy = null; if (pZone != null && pZone.m_pCopyObject != null) { //in case of being called at sub class pCopy = pZone.m_pCopyObject as CCEaseElasticInOut; } else { pCopy = new CCEaseElasticInOut(); pZone = pNewZone = new CCZone(pCopy); } pCopy.initWithAction((CCActionInterval)(m_pOther.copy()), m_fPeriod); return pCopy; }
public override void OnEnter() { base.OnEnter(); var s = CCDirector.SharedDirector.WinSize; var move = new CCMoveBy (3, new CCPoint(s.Width - 130, 0)); var move_ease_inout1 = new CCEaseElasticInOut((CCActionInterval) (move.Copy()), 0.3f); var move_ease_inout_back1 = move_ease_inout1.Reverse(); var move_ease_inout2 = new CCEaseElasticInOut((CCActionInterval) (move.Copy()), 0.45f); var move_ease_inout_back2 = move_ease_inout2.Reverse(); var move_ease_inout3 = new CCEaseElasticInOut((CCActionInterval) (move.Copy()), 0.6f); var move_ease_inout_back3 = move_ease_inout3.Reverse(); var delay = new CCDelayTime (0.25f); var seq1 = CCSequence.FromActions(move_ease_inout1, delay, move_ease_inout_back1, (CCFiniteTimeAction) delay.Copy()); var seq2 = CCSequence.FromActions(move_ease_inout2, (CCFiniteTimeAction) delay.Copy(), move_ease_inout_back2, (CCFiniteTimeAction) delay.Copy()); var seq3 = CCSequence.FromActions(move_ease_inout3, (CCFiniteTimeAction) delay.Copy(), move_ease_inout_back3, (CCFiniteTimeAction) delay.Copy()); m_tamara.RunAction(new CCRepeatForever (seq1)); m_kathia.RunAction(new CCRepeatForever (seq2)); m_grossini.RunAction(new CCRepeatForever (seq3)); }
protected CCEaseElasticInOut(CCEaseElasticInOut easeElasticInOut) : base(easeElasticInOut) { }