I want to make it so you can't move after you say "/e lay", which means my walkspeed would have to be 0 and the animation stops by saying "/e up" my walkspeed would go back to normal (which would be 16), but I don't know how to put that in the script.
Script:
game.Players.PlayerAdded:connect(function(Plr)
Plr.Chatted:connect(function(msg)
if msg == "/e lay" then -- You could replace the MSG with anything if you want
A = Instance.new("Animation", Plr.Character)
A.AnimationId = "http://www.roblox.com/Asset?ID=2674544973" -- Here replace the 00s with your Animation ID
animTrack = Plr.Character.Humanoid:LoadAnimation(A)
animTrack:Play()
end
end)
end)
=========================================================================================================================================================
Video of animation in game: https://gyazo.com/d7f6d8ea7a7ba47d87c5c7599b48b153
