The function works but only when I take out one of the keys. How do I make it work when both are pressed and not just one because this script does not work unless I take out if input.KeyCode == Enum.KeyCode.W then.
Hope I explained this right
game:GetService("UserInputService").InputBegan:connect(function(input)
if input.KeyCode == Enum.KeyCode.W then
if input.KeyCode == Enum.KeyCode.LeftShift and action == "none" then
player.Character.Humanoid.WalkSpeed=21
action = "sprint"
end
end
end)

1 comment
Thanks so much this works now I understand!