Hello, I am working on making a dabbing script in my game and I want it to activate through "/e dab. It isn't working and I'm not sure why. It is located in Starter Player Scripts and it's a local script.
local animation = Instance.new("Animation")
animation.AnimationId = "rbxassetid://636749560"
local animtrack = nil
local canplay = true
function processCommand(speaker, message)
if message == "/e dab" then
if canplay then
canplay = false
local Cname = speaker.Name
local character = game.Workspace.Cname
animtrack = character.Humanoid:LoadAnimation(animation)
animtrack:Play()
end
end
end
Any help is appreciated.

1 comment
You didn't set up anything to fire when the player chats.