Skip to main content

Interaction NUG

Overview

The Interaction NUG handles how the player finds, views, and triggers interactable objects in the world.

Use it for doors, pickups, switches, NPCs, signs, power-ups, terminals, chests, and any actor that needs player-triggered behaviour.

Core Assets

  • AC_Interact
  • BPI_Interactable
  • WBP_InteractPrompt

What The System Does

  • Finds interactable actors
  • Checks whether actors implement the interaction interface
  • Stores the current interactable target
  • Shows or hides an interaction prompt
  • Sends interaction input to the target actor
  • Keeps player interaction logic separate from the object being used

Quick Setup

Use this section to test one interactable object.

  1. Add AC_Interact to the player character.
  2. Add BPI_Interactable to the actor that should be interacted with.
  3. Set the trace distance or detection range.
  4. Set the object types the system should detect.
  5. Assign the prompt widget.
  6. Press Play.
  7. Look at or move near the interactable actor.
  8. Check that the prompt appears.
  9. Press the interact input.
  10. Confirm the actor runs its interaction logic.

Runtime Flow

  1. The player looks for interactable actors using the interaction component.
  2. The component checks whether the detected actor implements BPI_Interactable.
  3. If valid, the actor becomes the current interactable.
  4. The prompt widget appears.
  5. The player presses the interact input.
  6. AC_Interact calls the interaction event on the target actor.
  7. The target actor decides what happens next.

Why This Is Modular

The Interaction NUG does not need to know what the target actor is.

A door can open.

A chest can reveal a reward.

A sign can show text.

A power-up can activate.

An NPC can start dialogue.

The interaction component only finds the actor and calls the interface. The actor owns the result.

Blueprint Tutorial

Goal

Create one working interactable actor that shows a prompt and reacts when the player presses the interact input.

Before You Start

Create or confirm these assets exist:

  • AC_Interact
  • BPI_Interactable
  • WBP_InteractPrompt
  • A player character Blueprint
  • A test actor Blueprint

Step 1, Add The Interaction Component

  1. Open the player character Blueprint.
  2. Add AC_Interact as an Actor Component.
  3. Set the trace or detection distance.
  4. Set the object types the component should detect.
  5. Assign the prompt widget class if the component owns prompt creation.
  6. Compile and save.

Step 2, Add The Interface To A Test Actor

  1. Open the test actor Blueprint.
  2. Add BPI_Interactable in Class Settings.
  3. Compile and save.
  4. Implement the interaction event from the interface.
  5. Add a simple test action, such as print string, toggle visibility, or open door.

Step 3, Connect The Input

  1. Open the player character or input handling Blueprint.
  2. Find the interact input action.
  3. On input pressed, call the interact function on AC_Interact.
  4. The component should use the current interactable target.
  5. If the target is valid, call the interface event.

Step 4, Add The Prompt

  1. Create or open WBP_InteractPrompt.
  2. Add clear prompt text, such as Press Interact.
  3. Keep the prompt small and readable.
  4. If the prompt is world-positioned, use the interactable actor or prompt target component as the location source.
  5. If the prompt is screen-space, project the world location to screen.

Step 5, Test The Result

  1. Press Play.
  2. Look at or move near the test actor.
  3. Confirm the prompt appears.
  4. Press the interact input.
  5. Confirm the test actor reacts.
  6. Move away or look away.
  7. Confirm the prompt hides.

Photo Slots

Use these slots when adding screenshots to the documentation site.

Interaction Component On Player

Image slot: interaction component on player.

Interface Added To Actor

Image slot: interface added to interactable actor.

Trace Or Detection Settings

Image slot: interaction trace or detection settings.

Prompt Widget Setup

Image slot: prompt widget setup.

Runtime Prompt Test

Image slot: runtime prompt test.

Blueprint Flow Placeholder

This is a temporary Klee render test using the working example from the playground.

Replace this with the real Interaction NUG Blueprint export when the final Blueprint logic is ready.

Interaction NUG Placeholder, BeginPlay Print String

Preparing Blueprint flow...

Show copied Blueprint source
Begin Object Class=/Script/BlueprintGraph.K2Node_Event Name="K2Node_Event_0"
  EventReference=(MemberParent=Class'"/Script/Engine.Actor"',MemberName="ReceiveBeginPlay")
  bOverrideFunction=True
  bCommentBubblePinned=True
  NodeGuid=DA78E90542B5EA6FFF2BB580420BADA4
  CustomProperties Pin (PinId=72D40BCB43A58F1C676E9AA9770D2D80,PinName="OutputDelegate",Direction="EGPD_Output",PinType.PinCategory="delegate",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(MemberParent=Class'"/Script/Engine.Actor"',MemberName="ReceiveBeginPlay"),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=True,PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,)
  CustomProperties Pin (PinId=43C25E4A4F36B0A3D974C58D187B99D0,PinName="then",Direction="EGPD_Output",PinType.PinCategory="exec",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=True,LinkedTo=(K2Node_CallFunction_8 347E2B8849A88B5B6EB338B0CF412295,),PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,)
End Object
Begin Object Class=/Script/BlueprintGraph.K2Node_CallFunction Name="K2Node_CallFunction_8"
  FunctionReference=(MemberParent=Class'"/Script/Engine.KismetSystemLibrary"',MemberName="PrintString")
  NodePosX=288
  AdvancedPinDisplay=Hidden
  EnabledState=DevelopmentOnly
  NodeGuid=D94D72E348471465CF685AB3C289A168
  CustomProperties Pin (PinId=347E2B8849A88B5B6EB338B0CF412295,PinName="execute",PinToolTip="\nExec",PinType.PinCategory="exec",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,LinkedTo=(K2Node_Event_0 43C25E4A4F36B0A3D974C58D187B99D0,),PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,)
  CustomProperties Pin (PinId=867BBF3A41E77FED7EBB01B783D1BD58,PinName="then",PinToolTip="\nExec",Direction="EGPD_Output",PinType.PinCategory="exec",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,)
  CustomProperties Pin (PinId=89FC8C6B4DB2E65B8FFC6CB80DC5386D,PinName="self",PinFriendlyName=NSLOCTEXT("K2Node", "Target", "Target"),PinToolTip="Target\nKismet System Library Object Reference",PinType.PinCategory="object",PinType.PinSubCategory="",PinType.PinSubCategoryObject=Class'"/Script/Engine.KismetSystemLibrary"',PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,DefaultObject="/Script/Engine.Default__KismetSystemLibrary",PersistentGuid=00000000000000000000000000000000,bHidden=True,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,)
  CustomProperties Pin (PinId=B74444DF4AA54A124612178F2F98CE1F,PinName="InString",PinToolTip="In String\nString\n\nThe string to log out",PinType.PinCategory="string",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,DefaultValue="Let's share Blueprints!",AutogeneratedDefaultValue="Hello",PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,)
End Object

Injected Blueprint Code Slots

These slots will be replaced with real auto-rendered BlueprintFlow blocks once each function is final.

AC_Interact, Find Interactable Function

AC_Interact Find Interactable Nodes
Paste exported Blueprint node code here.

AC_Interact, Interact Function

AC_Interact Interact Nodes
Paste exported Blueprint node code here.

BPI_Interactable, Actor Interaction Event

BPI_Interactable Actor Interaction Event Nodes
Paste exported Blueprint node code here.

Prompt Widget Update

Interact Prompt Widget Nodes
Paste exported Blueprint node code here.

Common Issues

Prompt Does Not Appear

Check that the target actor implements BPI_Interactable.

Also check that the trace or detection object types include the actor collision type.

Actor Is Detected But Cannot Interact

Check that the interact input calls the interaction function on AC_Interact.

Also check that the current interactable reference is valid.

Prompt Appears In The Wrong Place

Check whether the prompt is using the actor location, component location, or screen projection.

For world prompts, use the interactable actor or prompt target component as the location source.

Prompt Is Stretched Or Squashed

Put the prompt content inside a ScaleBox or SizeBox.

Set a clear desired size.

Interaction Fires Constantly

Only call the interaction event when the input is pressed.

Detection can update often, but interaction should be input-based.

It Only Works From One Camera Angle

Check the trace start and direction.

If the game uses multiple cameras, make sure the trace uses the active camera or the intended view source.

Extension Notes

  • Add prompt target components for cleaner widget placement later
  • Add support for interaction priority if multiple objects are detected
  • Add icon support for different interaction types
  • Add gamepad and keyboard prompt switching later
  • Keep interaction logic interface-based so other NUGS can use it without hard dependencies

Testing Checklist

  • Player can detect an interactable actor
  • Prompt appears when the actor is valid
  • Prompt hides when the actor is no longer valid
  • Interact input calls the target actor
  • Non-interactable actors are ignored
  • Door interaction works
  • Power-up or collectible interaction can be added later
  • Prompt location is readable in first-person and third-person views
  • Interaction does not fire every tick
  • The system still works when other NUGS are not installed