keyboard_check_released

Returns whether the given key on the keyboard has just been released.

Syntax:

GML Code Example

keyboard_check_released(key);


Argument Description
key The key to check the released state of.


Returns: Boolean


Description

With this function you can check to see if a key has been released or not. Unlike the keyboard_check function, this function will only run once for every time the key is lifted, so for it to trigger again, the key must be first pressed and then released again.


Example:

GML Code Example

if keyboard_check_released(ord('P'))
    {
    instance_create(0, 0, obj_Pause);
    }
 

The above code will check to see if the "P" key has been released and if so, create an instance of "obj_Pause".





No Examples Submitted

Does this page need better examples? Be the first to Submit

No Edits Suggested

Is this page unclear or not descriptive enough? Suggest an edit to the page and with enough upvotes your changes will be made.

No Questions Have Been Ask

Do you have a question about this page? Ask it Here