Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Create a UserInput with numbers?

Is it possible to make a UserInput but instead of using Keyboard inputs, how would you use Numbers?

4 comments

0

are you referring to the numbers on your keyboard?

0

Enum.KeyCode.Six, Enum.KeyCode.Zero? assuming you're talking about UserInputService. https://wiki.roblox.com/index.php?title=API:Enum/KeyCode

0

Oh alright, just looked into the Enums and there are "Keypad" usages.

0

Actually, no. KeyPad is only for the numbers to your right of the keyboard. Let me be more specific next time. How do you make UserInputService to where you can use the numbers in front of your keyboard instead of letters.

1 answer

✓ Accepted answer
local UIS = game:GetService("UserInputService")

UIS.InputBegan:Connect(function(Input)
	local Input = Input.KeyCode
	if Input == Enum.KeyCode.Six then
		print("The [6] key was pressed!")
	end
end)

This discussion is preserved as it was. New answers, comments, and votes are closed.