How do I unbind WASD

I know you can do this by using this code below, but it also unbinds spacebar. I just want the WASD to be unbinded, not the spacebar.

--[SERVICES]--
local Players = game:GetService("Players")

--[VARIABLES]--
local Player = Players.LocalPlayer
local Controls = require(Player.PlayerScripts.PlayerModule):GetControls()

--[CODE]--
Controls:Disable()
1 Like

try this mayebe? “if Controls == Spacebar then return end”

Just change the playermodule to suit your needs

ContextActionService can only bind 1 function to a key at a time for whatever reason, so you could bind WASD to something like function() return end

Try ContextActionService:BindAction("FreezeMovement", function() return end, false, Enum.Keycode.W, Enum.Keycode.A, Enum.Keycode.S, Enum.Keycode.D)

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.