/** creates an initializes the action with the property name (key), and the from and to parameters. */ public static CCActionTween create(float aDuration, string key, float from, float to, CCActionTweenDelegate d) { CCActionTween pRet = new CCActionTween(d); pRet.initWithDuration(aDuration, key, from, to); return(pRet); }
public void SetZoomScaleInDuration(float s, float dt) { if (dt > 0) { if (container.ScaleX != s) { CCActionTween scaleAction = new CCActionTween(dt, "zoomScale", container.ScaleX, s); RunAction(scaleAction); } } else { ZoomScale = s; } }
public void SetZoomScaleInDuration(float s, float dt) { if (dt > 0) { if (Math.Abs(_container.ScaleX - s) > 0.1) { var scaleAction = new CCActionTween(dt, "zoomScale", _container.ScaleX, s); RunAction(scaleAction); } } else { ZoomScale = s; } }
public override void onEnter() { base.onEnter(); centerSprites(3); CCSize s = CCDirector.sharedDirector().getWinSize(); CCActionInterval actionTween1 = CCActionTween.actionWithDuration(3, "tamara", 25f, 250f, new CCActionTweenDelegate(myTween)); CCActionInterval actionTween2 = CCActionTween.actionWithDuration(3, "grossini", 150f, 260f, new CCActionTweenDelegate(myTween)); CCActionInterval actionTween3 = CCActionTween.actionWithDuration(3, "kathia", 75f, 250f, new CCActionTweenDelegate(myTween)); // source code: CCActionInterval* actionByBack = actionBy->reverse(); CCFiniteTimeAction actionTween1Back = actionTween1.reverse(); m_tamara.runAction(actionTween2); m_grossini.runAction(CCSequence.actions(actionTween1, actionTween1Back)); m_kathia.runAction(actionTween3); }
/** creates an initializes the action with the property name (key), and the from and to parameters. */ public static CCActionTween create(float aDuration, string key, float from, float to, CCActionTweenDelegate d) { CCActionTween pRet = new CCActionTween(d); pRet.initWithDuration(aDuration, key, from, to); return pRet; }
public override CCFiniteTimeAction Reverse() { return(CCActionTween.create(Duration, m_strKey, m_fTo, m_fFrom, m_pDelegate)); }
public static CCActionTween actionWithDuration(float aDuration, string key, float from, float to, CCActionTweenDelegate d) { return(CCActionTween.create(aDuration, key, from, to, d)); }