double tap with ContextActionService?
im trying to make it so when the player double taps W it will make them run but as of currently im just stuck here not knowing how to script the rest
heres the code
01 | local Service = game:GetService( "ContextActionService" ) |
03 | Service:BindAction( "Humanoid SpeedBoost" , function (LeftShift, InputState, InputObject) |
04 | if InputState = = Enum.UserInputState.Begin then |
05 | script.Parent.Humanoid.WalkSpeed = 32 |
08 | script.Parent.Humanoid.WalkSpeed = 16 |
10 | end , false , Enum.KeyCode.W) |