How the animation should look: How it looks on a player:
The priority on the animation is action, I don't know what could be interfering
Code on dummy (works fine when i run the game):
local anim = Instance.new("Animation") anim.AnimationId = "rbxassetid://11262438869" local a = script.Parent.Humanoid.Animator:LoadAnimation(anim) a.Looped = true a:Play()
Code on player in startercharacterscripts (doesn't work lol):
repeat task.wait() until script.Parent local humanoid: Humanoid = script.Parent:WaitForChild("Humanoid") local anim = Instance.new("Animation") anim.AnimationId = "rbxassetid://11262438869" local track = humanoid.Animator:LoadAnimation(anim) track.Looped = true humanoid.Running:Connect(function(s) if s > 0 then track:Play() else track:Stop() end end)
Hi, I made an animation system before. Put a script in StarterCharacterScripts. Then insert a folder in the script and rename it to Settings. In the folder place a boolvalue and a number value. Rename boolvalue to Enabled. Rename Numbervalue to Speed. Then insert animation into the script. Rename it to IdleAnimation. Make sure you go to properties tab and put your animation id into it. Here is the script:
--Variables-- local set = script.Settings local sp = set.Speed local enabled = set.Enabled local hum = script.Parent:WaitForChild("Humanoid") if hum then print("Success") else print("No Humanoid") end local humanim = hum:LoadAnimation(script:FindFirstChildOfClass("Animation")) --Playing Animation-- if enabled.Value == true then humanim:Play() humanim.Looped = true humanim:AdjustSpeed(sp.Value) end
Hope this helps and you understand. let me know if it doesn't work or you got stuck.