# SpoofInputEvent

Can be used to spoof keys being held down or released.

### Example

```ts
script.addListener("SpoofInputEvent", (event) => {
    if (event.keyBinding == mc.gameSettings.keyBindSprint) {
        event.pressed = true;
    }
});
```

### Properties

#### pressed

> **pressed**: `boolean`

Modify this to spoof the key state.

### Methods

#### getKeyBinding()

> **getKeyBinding**(): [`MCKeyBinding`](https://scripting.breeze.rip/api/net/minecraft/client/settings/mckeybinding)

Gets the key binding that was pressed.

**Returns**

[`MCKeyBinding`](https://scripting.breeze.rip/api/net/minecraft/client/settings/mckeybinding)
