EaseTween version 1.5 (experimental)
There're alot of changes I made since 1.4.
One of my concern for easeTween is that several action and combination of parameter behaves very strangely.
One example would be 1.4 reverse action.
People would expect that reverse action plays the animation backward, no matter when you called it. However in 1.4 it only play the tween in reverse if you already played the animation once. The progress expression also became really messy...
That's only one example. There are alot more annoyances like:
- What'll happen if I play the tween multiple time?
in 1.4: If the tween is playing, the play action will be ignored
in 1.5: Same as 1.4, but you can now force play it to change direction midtween
- Sometimes, changing the parameter of the tween using action needs alot of action
in 1.4: In the worst case, you need 8 action
in 1.5: There's a 'Parameter Set' action, you can change all 8 parameter with one action
- We can't control where the position/angle/anything will end up if we stop it in midtween
in 1.5: You can stop it in the current position, reset it back or put it on the tween target
- What exactly is reverse action ?
in 1.4: It is used to rewind the already played tween
in 1.5: Play the animation in reverse
- Alot more, especially with relative and absolute introduced back in 1.4
I think it is also time to explain things like:
- The difference between all play mode
loop: play, rewind, play, rewind, loop to infinity
repeat: play, play, play, loop to infinity
play once: play
ping pong: play, reverse, play, reverse, loop to infinity
ping pong once: play, reverse
- How relative works in tweened property (in 1.5):
Position: Change the position force set to the initial position then tween to initial+target position.
Size: Change the size, force set to the initial ratio, then tween to initial*target ratio.
Size Pixel: Change the size, from initial pixel size to initial+target size.
Opacity: Change the size, from initial opacity to initial+target opacity.
Angle: Change the angle, from initial angle to initial+target angle.
- How does 'current' keyword works?
If you enter current in initial, it will use current position/angle/whatever.
For now, setting the current in target still need some works, I haven't tested it yet.
- Group tween is introduced in 1.5:
You can now put several object in a tween group. To use it,
1. Set the objects tween group on the property
(you can set different tweens and different objects to same group, so that they played at the same time)
2. The group progress condition is used to track the group progress.
The group progress is the slowest progress of all the tween in the group.
If you have two object A and B, with different duration, the one with the biggest duration is the group progress.
note: There are no onGroupTweenEnd yet, I may or may not add it in the future.
3. Use Group Playback actions to control it
added: group tween feature
added: force reverse, force start
added: smoothstep easing function
added: parameter set action
I still keep the 1.4 version in the download link until the 1.5 became more stable.
I am still thinking of a good way to add real tween group and queue so we only need one easetween behavior per object to tween several property at once.
Please notify me if there're any bugs...
I don't know if this is useful or not, but i think this capx could be use as a reference to test various tween mode