How to make character move when he's moved in the animation too

I want to make a sword ability and when you press the q it will dash you. However, when the animation finished it moves back to the previous position.
I have tried using a Smart animation plugin I found, but it was moving all the time during the animation without stopping where it should have.
Here is a video:

External Media
1 Like

Hi you shouldn’t move the character IN the animation but make the animation static then add an event to your desired keyframe when you want to move your character in the animation editor and name it. After that you play the animation and use the function :GetMarkerReachedSignal() that will fire once the animation reached the previously created animation event in the animation editor by putting its name in the parenthesis.

I thought of adding the part where the animation is not moving and then adding a vector force to make the character move when it ends. Would you recommend that?

Yes just wait until it’s the right time to move your character then destroy your vectorForce after some time so that the player won’t move infinitely

1 Like

Thank you for the suggestion, I will try your idea

The problem with vector frame is that it takes a while to start what else can I use so it starts immediately?

linear velocity is a good choice perhaps tweening the position would be good although a bit janky just make sure you raycast in front of the player to detect if there’s an obstacle in front of him when using linear velocity if so disable it because if the player collides with something when using linear velocity it could fling him to space

1 Like

dont tween position for moving the character around, thats never a good option, instead as you said, bodyMovers are what is best to use

1 Like