wait() local WA = Instance.new("Animation") local IA = Instance.new("Animation") local JA = Instance.new("Animation") IA.AnimationId = "rbxassetid://2864159998" JA.AnimationId = "rbxassetid://2864429112" WA.AnimationId= "rbxassetid://2864578077" local humanoid = script.Parent.Humanoid local IdleAnimation = humanoid:LoadAnimation(IA) local JumpAnimation = humanoid:LoadAnimation(JA) local WalkAnimation = humanoid:LoadAnimation(WA) humanoid.Running:Connect(function(s) if s > 1 then IdleAnimation:Stop() WalkAnimation:Play() else IdleAnimation:Play() WalkAnimation:Stop() end end) humanoid.Jumping:Connect(function(s) if s > 1 then print("lol") end end)
Well, the paramater on the Running
and Jumping
event is a boolean value, so it will either be false or true, and you obviously can't compare a boolean and a number. So I guess what you want to do is check if it's true. So that's waht you gotta do, and always keep on mind that paramaters are almost never numbers, they are all the time just a bool or an object as incapaz said.
Now this is waht you wanna do:
humanoid.Running:Connect(function(s) if s == true then IdleAnimation:Stop() WalkAnimation:Play() else IdleAnimation:Play() WalkAnimation:Stop() end end) humanoid.Jumping:Connect(function(s) if s == true then print("lol") end end)