So I am trying to find out how to get a keycode like this Enum.KeyCode.Enter Here is my script:

game:GetService("UserInputService").InputBegan:Connect(function(input)
	if input == Enum.KeyCode.KeypadEnter then
	print ' reeeeee  '
end
end

And I would like to change Enum.KeypadEnter to just the Enter key. How would I go about doing that?

6 comments

3

Enum.KeyCode.Return I believe

2

Yeah, Enum.KeyCode.Return is enter.

0

yes all of you

0

i believe thats correct, you have print"reeee" instead of print("reeeee")

0

Lua isn't Python 2; only Python 2 has print as a command and not a function. However, Python 3 uses print as a function, like Lua.

0

Excuse me. I believe there is a print command on roblox correct me if I am wrong but print() ????