Animation ending with offset causes unintended fling/velocity issue

In my game Ink Game, if you play an animation that ends with a large offset from the HumanoidRootPart, it causes a strange velocity/flinging issue. When the animation ends, if the player touches another character (or another player touches them), they are sent flying with extreme force.

Animation
rbxassetid://133906652471025

Script

local char = workspace.Live.o0llchangedll0o
local anim = char.Humanoid.Animator:LoadAnimation(game.ReplicatedStorage.Animations.Cutscenes.SkySquidGamesIntro.Player1)
char.HumanoidRootPart.Anchored = true
anim:Play()
anim.Stopped:Wait()
char.HumanoidRootPart.Anchored = false

Clip

or
Watch weird velocity bug with anims | Streamable (if not expired)

Expected behavior

When an animation ends, players should not gain unintended velocity or fling others, even if the animation ends with an offset from the root.

Hi, this happens because you are moving the character’s lower torso with Motor6d’s but their physical location in the game is constant (where the HumanoidRootPart is). When you move the lower torso with animation, it moves kinematically, and that translation is a result of applying the content of the animation at a specific frame. When the animation loops around, that offset goes back to 0 with infinite force (it is kinematic motion, not dynamic)

What you are trying to achieve is something called RootMotion, where the root is driven by animation data, but actually physically moving the HumanoidRootPart (with impulses). This isn’t currently support on Roblox out of the box, though we are looking to add this feature to the motion system.

when are you guys adding rootmotion? im really looking foward to it.

No specific data at this point, we’ve got a few things we’re cooking up that have to ship first :slight_smile: