I tried to make an Animation script that will make you emote when you press E. But the problem is it wont play and it doesn't show any error on the output.
wait(1) userinput = game:GetService("UserInputService") plr = game.Players.LocalPlayer.Character anim = plr.Humanoid:LoadAnimation(script.anim) userinput.InputBegan:connect(function(input) if input.KeyCode == Enum.KeyCode.E then anim:Play() end end)
wait(1) userinput = game:GetService("UserInputService") plr = game.Players.LocalPlayer.Character animation = Instance.new("Animation") animTrack = nil anim = plr.Humanoid:LoadAnimation(script.anim) userinput.InputBegan:connect(function(input) if input.KeyCode == Enum.KeyCode.E then animation.AnimationId = " " -- paste your animation id here (HAS TO BE CREATED BY YOU OR IT WON'T WORK) animTrack = plr.Humanoid:LoadAnimation(animation) animTrack:Play() end end)
When you make an animation in the Animation Editor, you need to remember to set the priority to Action.
Hi, i've had this problem but managed to fix it. By any chance are you making the animation and saving it to yourself but editing a group game. Because if so then that is the reason. Try publishing the animation to your group instead and taking the id