As you can see in the title, my question is simple. For UserInputService, how do make a hold input? As pro developers must have seen, UIS is really chunky. You have to keep pressing that button rapidly and repeatedly. How do we make a hold input? Like in a normal roblox character, you HOLD "W" to move. How is that? Is there a way to write it in code?
local UserInputService = game:GetService("UserInputService") local aKeyPressed = false UserInputService.InputBegan:Connect(function(input,GameProcessedEvent) if input.KeyCode == Enum.KeyCode.A then aKeyPressed = true while aKeyPressed == true do wait() print ("A-Key is being held down!") end end end) UserInputService.InputEnded:Connect(function(input,GameProcessedEvent) if input.KeyCode == Enum.KeyCode.A then aKeyPressed = false end end)