add_key_mapping
Add a key-to-action mapping to an Input Mapping Context in Unreal Engine, binding a physical key to an input action with optional triggers and modifiers.
Instructions
Add a key-to-action mapping to an Input Mapping Context.
Args: context_path: Path to the IMC asset action_path: Path to the InputAction asset key: Key name (e.g. "SpaceBar", "W", "Gamepad_LeftY", "LeftMouseButton") triggers: Optional list of triggers, each {"type": "InputTriggerHold", "properties": {...}} modifiers: Optional list of modifiers, each {"type": "InputModifierNegate", "properties": {...}}
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"context_path": "<context_path>",
"action_path": "<action_path>",
"key": "<key>"
},
"name": "add_key_mapping"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | ||
| triggers | No | ||
| modifiers | No | ||
| action_path | Yes | ||
| context_path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |