# On Key Press

## Overview

![The On Key Press Node.](https://2561100106-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ff6JZovzOqBctA4C1o76u%2Fuploads%2Fgit-blob-5fd511feefb397ad40da7e3946e3c61538f7951b%2Fonkeypressupdatedimage.png?alt=media)

**On Key Press** is an **Event Listener** **Node** used for executing a **Logic Branch** when a key is pressed on a computer keyboard.

[**Scope**](https://docs.incari.com/incari-studio/2023.2/overview#scopes): **Scene**, **Prefab**.

## Attributes

![The On Key Press Node Attributes.](https://2561100106-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ff6JZovzOqBctA4C1o76u%2Fuploads%2Fgit-blob-5ee36838c617dbb233dfb1625af7c87c3f1a0e5c%2Fonkeypressattributes.png?alt=media)

### Miscellaneous

| Attribute        | Type     | Description                                                                                           |
| ---------------- | -------- | ----------------------------------------------------------------------------------------------------- |
| `Repeat Enabled` | **Bool** | Whether or not the **Event** is triggered while the key is held down, or just when initially clicked. |

### Event

| Attribute | Type          | Description                             |
| --------- | ------------- | --------------------------------------- |
| `Key`     | **Drop-down** | The key that **Incari** will listen to. |

## Outputs

| Output             | Type      | Description                                                                                                                                                                                                                                                                        |
| ------------------ | --------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| *Pulse Output* (►) | **Pulse** | Moves onto the next part of the **Logic** once the assigned key is pressed (or held).                                                                                                                                                                                              |
| `Is Alt`           | **Bool**  | Whether or not the **Alt** key was also pressed in combination with the assigned key.                                                                                                                                                                                              |
| `Is Ctrl`          | **Bool**  | Whether or not the **Ctrl** key was also pressed in combination with the assigned key.                                                                                                                                                                                             |
| `Is Shift`         | **Bool**  | Whether or not the **Shift** key was also pressed in combination with the assigned key.                                                                                                                                                                                            |
| `Is Repeated`      | **Bool**  | Indicates whether this is a repeated/subsequent execution of the **Event** (`true`) or the initial time it is executed (`false`). If the `Repeat Enabled` **Attribute** is enabled, the output will always be `false` because the **Event** is only executed on the initial press. |

## See Also

* [**Events**](https://docs.incari.com/incari-studio/2023.2/toolbox/events)
* [**Keyboard**](https://docs.incari.com/incari-studio/2023.2/toolbox/events/keyboard)
* [**On Key Release**](https://docs.incari.com/incari-studio/2023.2/toolbox/events/keyboard/on-key-release)
