Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

Why wont my animations script work and help also?

Asked by 9 years ago

This script iv'e made should work but I don't know why it isn't. Could anyone tell me what is wrong or how to fix it?

prefix = "/e "
game.Players.PlayerAdded:connect(function(p)
p.Chatted:connect(function(m)
m = m:lower()
if m == prefix.."twerk" then
local a = Instance.new("Animation",p.Character)
a.AnimationId = "rbxassetid://144704979"
local h = p.Character:FindFirstChild'Humanoid'
local t = h:LoadAnimation(a)
t:Play()
--elseif m == prefix.."" then
--code
end
end)
end)

Answer this question