Hi, so I am making a script that Utalises the UserInputService where when you click, an animation plays, but as you could guess it does not work. I have already looked through the roblox dev forum and to my knowledge I am doing everything correct; the animation priority is set to core, I am using a local script inside StarterCharacterScripts,and the code is riight (I have no errors in the output and no typos.) This is the code:
local service = game:GetService("UserInputService")
local Player = game.Players.LocalPlayer -- this also only works in LocalScripts local Character = Player.Character local Humanoid = Character:WaitForChild("Humanoid")
local Animation = Instance.new("Animation") Animation.AnimationId = "rbxassetid://6723323427"
local Track = Humanoid:LoadAnimation(Animation)
service.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 then print("button is down") Track:Play() end end)
May I have some help please.

2 comments
Thanks, along with this, I changed the avatar type in game from r6 to r15 and it works.I believe this is because i created the animation on an r15 rig.
I agree with Jasmin, because if you didnt know there is update. If you know, the animator can be create through Instance.new or by the animation editor.