Simulates a complete press-and-release of the given key.
The keycode is a Win32 Virtual Key Code, not a Roblox Enum.KeyCode value. For letters, pass the uppercase ASCII byte (string.byte("A") returns 65, which is VK_A). Learn more here.
The Roblox window must be focused for the call to register. See iswindowactive().
Parameters
Returns
void
Aliases
Example
In a typing game, listen for the Sound the engine spawns under workspace each round and tap out its Name letter by letter.
Equivalent to calling keypress followed immediately by keyrelease.