Skip to content

keyboard_string

drewmccluskey edited this page Feb 12, 2019 · 1 revision

keyboard_string

string variable with the string of keyboard chars in the order in which they were pressed

Returns: string

Description:

This is a variable holding the list of inputted chars in the order which they were pressed. It is very useful for writing text in a game such as in a chat bar or a search. To clear the keyboard string for starting over, simply set keyboard_string = "";

Example:

if (keyboard_check_pressed(Keys.R))
{
    show_debug_message(keyboard_string.ToString());
}

This code will write the keyboard string to a debug message when the user presses the Enter key.

Back to Keyboard

Clone this wiki locally