How do I stop the default idle animation?

Hi, I’m trying to make an animation play when you trigger a proximity prompt. However, the default idle animation is interrupting it. Here’s what it looks like.

and here’s my script.

game.ReplicatedStorage.PlayCameraEnterAnim.OnServerEvent:Connect(function(plr)
	local anim = plr.Character.Humanoid:LoadAnimation(script.CameraSitEnter)
	anim.Looped = false
	anim:Play()
end)
1 Like

When an animation is finished it will revert back to the old position. To solve this, I think you would need to make an animation with a single keyframe with priority set to Action, and Looped set to true.

And whenever the cutscene ends, you should stop the animation.

Set the priority to action and looped to true.

Code:

game.ReplicatedStorage.PlayCameraEnterAnim.OnServerEvent:Connect(function(plr)
	local anim = plr.Character.Humanoid.Animator:LoadAnimation(script.CameraSitEnter)
	anim.Priority = Enum.AnimationPriority.Action
	anim.Looped = true
	anim:Play()
end)

thanks, both of these work.

limit

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.