map_input_action
Binds a key to an Enhanced Input action in an input mapping context using full asset paths and saves the context, so agents can add verified mappings to Unreal Engine input assets.
Instructions
Bind a key to an InputAction in an Enhanced Input mapping context, both by full asset path (add_mapping_to_context takes short names), and save the context. A context that already maps that key to that action is left as it is (added false, already_mapped true, not saved); a new mapping succeeds only when the context reaches disk. Other actions on the same key are not checked: use find_free_input_key or list_all_input_mappings first.
Returns: { context_path, action_path, key_name, index, mapping_count, added, already_mapped, saved, save_error? }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | No | Alias of key_name, read only when key_name is absent (same FKey names). | |
| key_name | No | Key name to map (e.g., "SpaceBar", "LeftMouseButton"). | |
| action_path | No | Full path to the InputAction asset. | |
| context_path | Yes | Full path to the InputMappingContext asset. | |
| input_action_path | No | Fallback for action_path when action_path is absent. |