Home / Guides / Unreal Engine Interaction System: Focus, Prompts and Pickups Done Right

Unreal Engine Interaction System: Focus, Prompts and Pickups Done Right

Press E on a door, a note, a lever. Interaction is everywhere in games, and it is easy to build in a way that gets painful as soon as you add a second kind of object. Here is a structure that scales.

1. Find what the player is looking at

Run a line or sphere trace from the camera on a timer (10 to 20 times a second is plenty, there is no need to do it every frame). Use overlap volumes only for "stand here to interact" cases. When several candidates exist, pick the one closest to the centre of the screen.

2. Talk to objects through an interface

Define one interface with a few functions: CanInteract, GetPrompt and Interact(Instigator). Doors, notes, pickups and levers all implement it. The player code never needs to know what it is interacting with, and you can add new object types without touching it.

3. Give clear focus feedback

Show the prompt only for the focused object, and highlight it. A custom-depth outline or a simple emissive pulse both work. Hide everything the moment focus is lost, including when the object is destroyed while focused.

4. Use Enhanced Input and hold actions

Map the interaction to an Enhanced Input action, and add a hold trigger for actions that should not happen by accident (opening a safe, taking a heavy item). Drive a progress ring from the same input value.

5. Carrying and moving things

A physics handle works for objects you drag around; attaching to a socket works for items you hold. Decide who owns collision while carried, and make sure an object can always be put down without ending up inside a wall.

6. Readable things: notes and documents

When the player reads something, pause only what needs pausing: block movement and camera input, blur or dim the background, and restore everything on close. Store "has been read" so that journals and objectives can use it later.

7. Locks, keys and codes

Keep the lock state on the door itself and let the key or PIN logic ask the door to unlock. Link keys to doors with a simple id so level designers can wire them up without writing code.

Common mistakes

Want working examples?

The Interactive Gameplay Kit ships 13 example interactions (focus highlight, carrying, a mineable rock, inspecting objects), the Basic Interactive Note System handles collecting and reading notes, the Simple Modular Door Pack covers doors, keys and PIN codes, and the Discovery Kit adds object inspection and a journal.

Related products

Tools that apply this

Need this built for your project?

I take on custom Unreal Engine, Unity and Blender work.

Request custom work