Relative value animation track. #4057
colorworlds
started this conversation in
Engine Core
Replies: 2 comments 1 reply
-
A pretty nice mock-up for a reworked Animation Editor has been proposed which I recall has this. |
Beta Was this translation helpful? Give feedback.
1 reply
-
The current approach would be parenting the node. You can move the parent of the Sprite from your code or in the editor, and let the animation move the Sprite itself inside the parent, which is relative to the parent. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Now the value of the animation track is fixed.
Sometimes this lacks flexibility.
For example, if a
Sprite Node
already has a position animation, it will be troublesome to change the initial position of theSprite
.For example, There is a
Sprite
has a track to change its position.The animation moves the sprite from position Vector2(0,100) to position Vector2(0,200) in 3 seconds.
Similar to the following:
If I move the initial position of the
Sprite
to Vector2(200,200).I may need to change the position animation to move the
Sprite
from position Vector2(200 + 0, 200 + 100) to position Vector2(200 + 0, 200 + 200) in 3 seconds.At present, I must manually modify each position of the
Sprite
on the animation track.The track may change to following:
This is what I mean by "Relative value animation track".
At this time, the value in the track represents not the current value of the Sprite, but the relative value relative to the initial value of the Sprite.
Using Tween Node can do similar things, but it must use code.
Beta Was this translation helpful? Give feedback.
All reactions