How would I accomplish This?

Hello. So recently I wanted to make taunts/custom emotes and It went ok…as in the animation worked but the only two issues were that The chair was not cloning on to the character, and the animation would glitch when I began moving instead of stopping the emote

This is the issue

giphy (1)

this is what It should look like

giphy

This is the script
    game.Players.PlayerAdded:connect(function(player)
    player.Chatted:connect(function(message)
	 processCommand(player, message)
    end)
end)


function processCommand(speaker, message)
    if message == script.MessageComand.Value then
		
		
		local bro = game.Workspace:FindFirstChild(speaker.Name)
		local newanim = script.AnimationOne:Clone()	
		newanim.Parent = bro
		local hum = newanim.Parent.Humanoid
		local anim = hum:LoadAnimation(bro.AnimationOne)
		anim:Play()
			
		newanim:Destroy()
		
		end
    end

If you want to see the glitch in a game join this and say “/e dance4”
The Test Game.

1 Like

You can change the walkspeed of the player to zero when they enter the command to prevent them from disabling the animation. Refarding the glitch, what is the animation priority of the animation you’re trying to play? Also I don’t see you cloning the chair anywhere in the script.

1 Like

One more thing is, you should use Animator. This class is auto added inside the humanoid of the player. Just load the animation like Animator:LoadAnimation(), this will return animation track.

1 Like

I want the emote to function like a Roblox emote so if you move it would disable the emote

I think you need to make the animation an action and loop it.

2 Likes

that’s my other issue I was planning on doing loadcharacter but that could lead to issues

so should the animation priority be action?

1 Like

It’s probably just animation priority, make sure the animation you are playing has more priority than core. Just like @crunchbone suggested.

2 Likes

ok that would make sense because the animations are under core instead of action.