I made a script that's supposed to play a Forward Dash animation after I double tap ''W'' and for some reason, it just won't play. I can't find the issue in the script anywhere. I made a local script and a normal script.
Local script:
local RepStore = game:WaitForChild("ReplicatedStorage")
local Store = RepStore:WaitForChild("Storage")
local RemoteStore = Store:WaitForChild("RemoveEvents")
local Remote = RemoteStore:WaitForChild("FDashEvent")
local Player = game.Players.LocalPlayer
local Mouse = Player:GetMouse()
local userinput = game:GetService("UserInputService")
Cool = true
Ws = 0
userinput.InputBegan:connect(function(input)
if input.KeyCode == Enum.KeyCode.W then
if Cool ~= true then return end
Ws = Ws + 1
if Ws > 2 then
Ws =2
end
if Ws == 2 then
Cool = false
Remote:FireServer()
wait(1)
Cool = true
end
wait(0.2)
Ws = 0
end
end)
===================================================================================================================================================
Regular script:
local RepStore = game:WaitForChild("ReplicatedStorage")
local Store = RepStore:WitForChild("Storage")
local RemoteStore = Store:WaitForChild("RemoveEvents")
local Remote = RemoteStore:WaitForChild("FDashEvent")
Remote.OnServerEvent:connect(function(player)
local Anim = Instance.new("Animation")
Anim.AnimationId ="rbxassetid://02667894858"
local move = player.Character.Humanoid:LoadAnimation(Anim)
move:Play()
local position = Instance.new("BodyVelocity",player.Character.HumanoidRootPart)
position.MaxForce = Vector3.new(5000000,5000000,5000000)
position.P = 100
position.Velocity = player.Character.HumanoidRootPart.CFrame.LookVector * 90
game.Debris:AddItem(position,.5)
===================================================================================================================================================
Any ideas?

4 comments
You can play player animations through a LocalScript and it will replicate to the server,
If you insert some
printstatements, which parts get called? (Is the object really spelledRemoveEvents?)Oh, I was really tired when I typed all of this, thanks for catching that typo.
Ok, the animation is playing now because I switched 'RemoveEvents' to 'RemoteEvents'