So I'm making a Bleach game and I've been trying to make and idle animation for my sword. I've looked at countless tutorials, but they don't work. What is wrong with my script? In the output it says "expected identifier when parsing expression, got ')" but I don't know what that means.
my script is:
moving=false Humanoid.Running:connect(function(value) if value>0 then moving=true else moving=false end
while wait() do
if not moving then
local animation = Instance.new("Animation")
animation.AnimationId = "http://www.roblox.com/Asset?ID=5171819946" local animTrack = Humanoid:LoadAnimation(animation) animTrack:Play() end) it also says for Humanoid W001:Unknown global Humanoid. I do not know what this means. I am new to scripting.
also sorry for bad formatting.

3 comments
W001:Unknown global Humanoid means that you haven't identified Humanoid. This means that the script doesn't know what the Humanoid is.
i can sell you a fully functioning sword script
Okay, but what can I do to fix it?