Class ccs.Tween
- Defined in: CCTween.js
- Extends ccs.ProcessBase
Constructor Attributes | Constructor Name and Description |
---|---|
Base class for ccs.Tween objects.
|
Method Summary
Class Detail
ccs.Tween()
Base class for ccs.Tween objects.
Method Detail
-
arriveKeyFrame(keyFrameData)Update display index and process the key frame event when arrived a key frame
- Parameters:
- {ccs.FrameData} keyFrameData
-
allocates and initializes a ArmatureAnimation.
// example var animation = ccs.ArmatureAnimation.create();
- Parameters:
- {ccs.Bone} bone
- Returns:
- {ccs.ArmatureAnimation}
-
{ccs.ArmatureAnimation} getAnimation()animation getter
- Returns:
- {ccs.ArmatureAnimation}
-
{Boolean} init(bone)init with a CCBone
- Parameters:
- {ccs.Bone} bone
- Returns:
- {Boolean}
-
play(movementBoneData, durationTo, durationTween, loop, tweenEasing)Start the Process
- Parameters:
- {ccs.MovementBoneData} movementBoneData
- {Number} durationTo
- {Number} durationTween
- {Boolean} loop
- {ccs.TweenType} tweenEasing
-
setAnimation(animation)animation setter
- Parameters:
- {ccs.ArmatureAnimation} animation
-
setBetween(from, to, limit)Calculate the between value of _from and _to, and give it to between frame data
- Parameters:
- {ccs.FrameData} from
- {ccs.FrameData} to
- {Boolean} limit
-
{ccs.FrameData} tweenNodeTo(percent, node)According to the percent to calculate current CCFrameData with tween effect
- Parameters:
- {Number} percent
- {ccs.FrameData} node
- Returns:
- {ccs.FrameData}
-
{Number} updateFrameData(currentPercent)Calculate which frame arrived, and if current frame have event, then call the event listener
- Parameters:
- {Number} currentPercent
- Returns:
- {Number}
-
updateHandler()update will call this handler, you can handle your logic here