C++ API Reference
This section highlights the main C++ types you typically interact with.
Public headers
Core:
Public/Data/EDInteractionTypes.h
Components:
Public/Components/EDIPlayerControllerComponent.h(UEDPlayerInteractionComponent)Public/Components/EDInteractableComponent.h(UEDInteractableComponent)Public/Components/EDInteractionGameStateComponent.h(UEDInteractionGameStateComponent)
UI:
Public/UI/EDInteractionWidget.h(UEDInteractionWidget)
Utilities:
Public/Library/EDInteractionLib.h(UEDInteractionLib)
Interfaces:
Public/Interfaces/EDInteractionNotifier.h(UEDInteractionNotifier/IEDInteractionNotifier)
Settings:
Public/Settings/EDInteractionSettings.h(UEDInteractionSettings)
Validation:
Public/Validation/EDInteractionConditionValidator.h(UEDInteractionConditionValidator)
Key runtime ownership
UEDPlayerInteractionComponentshould be owned by aAPlayerController.UEDInteractionGameStateComponentshould be owned byAGameStateBase(server authority).UEDInteractableComponentshould be owned by interactable actors.
Typical usage patterns
Start/stop interaction from code
if (UEDPlayerInteractionComponent* Comp = MyPC->FindComponentByClass<UEDPlayerInteractionComponent>())
{
Comp->Interact(true);
}
Listen to interaction events on an interactable
InteractableComponent->OnInteractionSuccessful.AddDynamic(this, &AMyActor::OnInteracted);
Implement the notifier interface
Implement UEDInteractionNotifier on your Pawn or PlayerController to receive centralized callbacks.
Example callbacks:
Local_OnInteractionDeniedLocal_OnInteractionServer_OnInteraction
Settings access
const UEDInteractionSettings* Settings = GetDefault<UEDInteractionSettings>();
Usage Examples
If you want practical, scenario-driven examples, see:
That section includes separate pages for:
- basic interactable actors
- items and consumables
- damage and traps
- GAS integration points
- quest/dialogue triggers
- notifier usage
- manual effect playback
- resource nodes
- server-side locking/reconfiguration
Validation API
The special-conditions validation API is documented here:
Server validation selection
The server validation policy is driven by:
Settings->ServerInteractionValidationType
And executed inside:
UEDPlayerInteractionComponent::TraceValidationActorUEDPlayerInteractionComponent::TraceValidationFoliage