Built-in Widgets
Ready-to-use widget classes included in the plugin. Each builds its own UMG layout in C++ and exposes style properties for customization. Subclass in Blueprint to override the visual design.
Overview
Targeting Widgets (ready to use)
Three concrete C++ classes for targeting UI, usable immediately:
| Widget | DisplayName | Purpose |
|---|---|---|
UERPBaseTargetFrameWidget | Elys Target Frame | HUD nameplate (name + icon) |
UERPBaseTargetReticleWidget | Elys Target Reticle | World-space lock-on reticle |
UERPBaseTargetHealthBarWidget | Elys Target Health Bar | Nameplate + health bar |
Interaction Widgets
Three concrete widgets plus two abstract base classes for custom implementations:
| Widget | DisplayName | Purpose |
|---|---|---|
UERPBaseMultiPressChallengeWidget | Elys Base Multi-Press Challenge | "Mash [E]" counter + progress bar |
UERPBaseRadialHoldWidget | Elys Base Radial Hold Challenge | Circular fill (Souls/Zelda style) |
UERPBaseWorldInteractionWidget | Elys Base World Interaction Prompt | World-space prompt on interactable actors |
UERPBaseTimedPressChallengeWidget | Elys Base Timed Press Challenge | Countdown bar + key prompt (QTE) |
UERPBaseTimingChallengeWidget | Elys Base Timing Challenge | Track with moving cursor + target zone (QTE) |
Abstract base classes (implement in Blueprint for custom designs):
| Base Class | DisplayName | Role |
|---|---|---|
UERPInteractionWidgetBase | — | Parent for all interaction prompts |
UERPChallengeWidgetBase | — | Parent for hold/multi-press challenge sub-widgets |
See the Widget Guide for patterns and Blueprint implementation examples.
Targeting Widgets
UERPBaseTargetFrameWidget
Header: UI/Targeting/ERPBaseTargetFrameWidget.h
HUD panel displaying the current target's name and icon, with optional tag-based name coloring (hostile = red, friendly = green).
Layout
Overlay
├── BackgroundImage (semi-transparent)
└── HorizontalBox
├── IconSizeBox > IconImage (collapsed if no icon)
├── Spacer (4px)
└── NameText
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
NameColor | FLinearColor | White | Default name color (no tag match) |
NameFont | FSlateFontInfo | Bold 16 | Font for the target name |
IconSize | float | 32 | Width and height of the icon |
BackgroundTint | FLinearColor | Black 60% | Background overlay color |
ContentPadding | FMargin | 12, 8 | Padding around the content |
Tag-Based Coloring
| Property | Type | Default | Description |
|---|---|---|---|
HostileColor | FLinearColor | Red | Color when target has HostileTag |
FriendlyColor | FLinearColor | Green | Color when target has FriendlyTag |
HostileTag | FGameplayTag | (none) | Tag that marks a target as hostile |
FriendlyTag | FGameplayTag | (none) | Tag that marks a target as friendly |
Priority order: hostile → friendly → default NameColor. Tags checked against FERPTargetDescriptor::TargetTags.
Set HostileTag and FriendlyTag in the class defaults of your Blueprint subclass. Common values: Target.Hostile, Target.Friendly.
Behavior
- OnDescriptorUpdated: Sets name text with tag-based color, loads icon from soft reference
- OnTargetActiveChanged: Toggles visibility (HitTestInvisible / Collapsed)
BindWidget Names
BackgroundImage (Image), IconSizeBox (SizeBox), IconImage (Image), NameText (TextBlock)
Usage
UERPBaseTargetFrameWidget* Frame = CreateWidget<UERPBaseTargetFrameWidget>(PlayerController);
Frame->HostileTag = FGameplayTag::RequestGameplayTag("Target.Hostile");
Frame->FriendlyTag = FGameplayTag::RequestGameplayTag("Target.Friendly");
Frame->AddToViewport();
// Wire from TargetingComponent events:
Frame->UpdateFromDescriptor(Descriptor);
Frame->SetTargetActive(true);
UERPBaseTargetHealthBarWidget
Header: UI/Targeting/ERPBaseTargetHealthBarWidget.h
Extends UERPBaseTargetFrameWidget with a health bar row below the name/icon. Bar color interpolates from HealthFullColor (100%) to HealthLowColor (0%).
Layout
Overlay
├── BackgroundImage
└── VerticalBox
├── HorizontalBox: [IconSizeBox] + Spacer + NameText
├── Spacer (gap)
└── SizeBox > HealthBar
Additional Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
HealthFullColor | FLinearColor | Green | Bar color at full health |
HealthLowColor | FLinearColor | Red | Bar color at zero health |
HealthBarHeight | float | 6 | Height of the health bar |
Inherits all style properties from UERPBaseTargetFrameWidget.
API
// Set health 0.0–1.0 (bar color interpolates automatically)
HealthBarWidget->SetHealthPercent(0.75f);
float Current = HealthBarWidget->GetHealthPercent();
BindWidget Names
Inherits BackgroundImage, IconSizeBox, IconImage, NameText, plus: HealthBar (ProgressBar)
UERPBaseTargetReticleWidget
Header: UI/Targeting/ERPBaseTargetReticleWidget.h
Minimal world-space reticle for soft-focus and lock-on visual states. Attach to a WidgetComponent on the target actor.
Layout
SizeBox
└── ReticleImage (tinted by focus/lock state)
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
FocusedColor | FLinearColor | White 60% | Color when soft-focused |
LockedColor | FLinearColor | Red | Color when locked on |
ReticleSize | float | 48 | Width and height of the reticle |
ReticleBrush | FSlateBrush | Solid white | Brush for the reticle image |
API
Reticle->SetLockedOn(true); // switches to LockedColor
Reticle->SetLockedOn(false); // switches to FocusedColor
bool bLocked = Reticle->IsLockedOn();
Delegates
| Delegate | Signature | Description |
|---|---|---|
OnLockStateChanged | (bool bLockedOn) | Broadcast when lock state changes |
Behavior
- OnTargetActiveChanged: Toggles visibility; resets lock state when target is lost
- OnLockStateChangedEvent: BlueprintNativeEvent — override for custom animations
BindWidget Names
ReticleSizeBox (SizeBox), ReticleImage (Image)
Usage
// Wire from TargetingComponent
Event: OnTargetLocked (Target, Descriptor)
-> Reticle -> SetLockedOn(true)
Event: OnTargetUnlocked (PreviousTarget)
-> Reticle -> SetLockedOn(false)
Event: OnDomainCandidateChanged (Previous, New, ChannelId)
-> Reticle -> SetTargetActive(IsValid(New))
Customizing with Blueprint Subclasses
All targeting widgets support BindWidget override — provide your own UMG layout in a Blueprint subclass.
How It Works
- Create a Widget Blueprint, set its parent to the C++ class (e.g.,
UERPBaseTargetFrameWidget) - In the UMG Designer, add widgets with the exact same names listed under BindWidget Names above
- Design your custom layout around those named widgets
- The C++ logic (descriptor updates, visibility toggling, color changes) works automatically with your designer widgets
All bound widgets use OptionalWidget = true — you only need to add the ones your design requires.
Interaction Widgets
Base Classes
| Base Class | Purpose |
|---|---|
UERPInteractionWidgetBase | Parent for all interaction prompts. Handles descriptor, focus, key display. |
UERPChallengeWidgetBase | Parent for hold/multi-press challenge sub-widgets. Receives progress (0..1). |
Concrete Interaction Widgets
Three ready-to-use interaction widgets are included:
| Widget | DisplayName | Purpose |
|---|---|---|
UERPBaseMultiPressChallengeWidget | Elys Base Multi-Press Challenge | "Mash [E]" press counter with progress bar |
UERPBaseRadialHoldWidget | Elys Base Radial Hold Challenge | Circular fill (Souls/Zelda style hold-to-interact) |
UERPBaseWorldInteractionWidget | Elys Base World Interaction Prompt | World-space prompt attached to the interactable actor |
UERPBaseMultiPressChallengeWidget
Header: UI/Interaction/ERPBaseMultiPressChallengeWidget.h
Extends UERPChallengeWidgetBase. Displays a "Mash!" prompt with a press counter ("3 / 5") and progress bar.
Layout
Overlay
├── BackgroundImage
└── VerticalBox
├── PromptText ("Mash!")
├── CounterText ("3 / 5")
└── ProgressBar
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
RequiredPresses | int32 | 5 | Total presses needed (for counter display) |
PromptLabel | FText | "Mash!" | Text above the counter |
CounterFont | FSlateFontInfo | Bold 18 | Font for the counter |
CounterTextColor | FLinearColor | White | Counter text color |
PromptFont | FSlateFontInfo | Regular 14 | Font for the prompt |
BarFillColor | FLinearColor | Blue | Progress bar fill color |
BackgroundTint | FLinearColor | Black 60% | Background color |
ContentPadding | FMargin | 12, 8 | Padding around content |
Behavior
- OnChallengeProgressChanged: Computes
CurrentPresses = Round(Progress * RequiredPresses), updates counter text and progress bar - OnChallengeCompleted: Sets counter to max, turns bar green (success) or red (failure)
- OnChallengeReset: Resets counter to "0 / N" and bar to 0%
BindWidget Names
BackgroundImage (Image), PromptText (TextBlock), CounterText (TextBlock), ProgressBar (ProgressBar)
UERPBaseRadialHoldWidget
Header: UI/Interaction/ERPBaseRadialHoldWidget.h
Extends UERPChallengeWidgetBase. Circular fill challenge display driven by a UMaterialInstanceDynamic.
Layout
Overlay
└── SizeBox (RadialSize × RadialSize)
└── Overlay
├── TrackImage (background circle)
├── RadialFillImage (driven by MID)
└── VerticalBox
├── IconImage (collapsed by default)
└── PromptText
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
FillColor | FLinearColor | Blue | Arc fill color (applied as "FillColor" MID param) |
TrackColor | FLinearColor | Dark gray 50% | Background track color |
RadialSize | float | 96 | Width and height of the radial widget |
PromptLabel | FText | (empty) | Center text |
PromptFont | FSlateFontInfo | Regular 12 | Center text font |
MaterialAsset | TSoftObjectPtr<UMaterialInterface> | (none) | Radial fill material (must have "Progress" scalar and "FillColor" vector params) |
Material Setup
Create a material M_ERP_RadialFill with:
- Scalar parameter
Progress(0..1) — drives the arc fill amount - Vector parameter
FillColor— tints the fill - Use
atan2on centered UVs to create a circular arc mask
If no material is assigned, the widget falls back to opacity-based feedback on a flat image.
BindWidget Names
TrackImage (Image), RadialFillImage (Image), IconImage (Image), PromptText (TextBlock)
UERPBaseWorldInteractionWidget
Header: UI/Interaction/ERPBaseWorldInteractionWidget.h
Extends UERPInteractionWidgetBase. Vertical-stacked prompt designed for world-space UWidgetComponent attachment on interactable actors.
Layout
Overlay
├── BackgroundImage
└── VerticalBox
├── IconSizeBox > IconImage (collapsed if no icon)
├── PromptText (object name)
└── KeyText ("[E]")
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
BackgroundTint | FLinearColor | Black 60% | Background color |
ContentPadding | FMargin | 12, 8 | Padding around content |
PromptFont | FSlateFontInfo | Regular 14 | Object name font |
KeyFont | FSlateFontInfo | Bold 16 | Key badge font |
KeyTextColor | FLinearColor | Yellow | Key text color |
IconSize | float | 32 | Width and height of the icon |
Behavior
- OnDescriptorUpdated: Sets prompt from
ObjectName, key from primary action's input binding, loads icon with async fallback - OnFocusChanged: Toggles visibility (HitTestInvisible / Collapsed)
BindWidget Names
BackgroundImage (Image), IconSizeBox (SizeBox), IconImage (Image), PromptText (TextBlock), KeyText (TextBlock)
Usage
ERPInteractableComponent already supports world-space via its WidgetSpace property. Set the widget class to UERPBaseWorldInteractionWidget and configure WidgetSpace = World on the interactable component.
UERPBaseTimedPressChallengeWidget
Header: UI/Interaction/ERPBaseTimedPressChallengeWidget.h
Extends UERPChallengeWidgetBase. Displays a countdown bar that drains over time and a key prompt. Used with ERPTimedPressChallenge.
Layout
Overlay
├── BackgroundImage
└── VerticalBox
├── PromptText ("[E] Now!")
└── CountdownBar (fills from right to left)
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
BarColor | FLinearColor | Blue | Bar color during normal countdown |
BarUrgentColor | FLinearColor | Red | Bar color when remaining time is below UrgentThreshold |
UrgentThreshold | float | 0.25 | Progress value (0..1) below which the bar switches to BarUrgentColor |
PromptFont | FSlateFontInfo | Bold 16 | Font for the key prompt |
PromptTextColor | FLinearColor | White | Key prompt text color |
BackgroundTint | FLinearColor | Black 60% | Background color |
ContentPadding | FMargin | 12, 8 | Padding around content |
Behavior
- OnChallengeProgressChanged: Updates bar fill percent and switches to
BarUrgentColorwhen progress drops belowUrgentThreshold - OnChallengeCompleted: Turns bar green (success) or red (failure)
- OnChallengeReset: Resets bar to full and default color
BindWidget Names
BackgroundImage (Image), PromptText (TextBlock), CountdownBar (ProgressBar)
UERPBaseTimingChallengeWidget
Header: UI/Interaction/ERPBaseTimingChallengeWidget.h
Extends UERPChallengeWidgetBase. Displays a horizontal track with a moving cursor and a highlighted target zone. Used with ERPTimingChallenge.
Layout
SizeBox (TrackWidth x TrackHeight)
└── Overlay
├── TrackImage (background)
├── TargetZoneImage (green highlight, positioned and sized from challenge config)
└── CursorImage (thin vertical line, moves left/right)
Style Properties
| Property | Type | Default | Description |
|---|---|---|---|
TrackWidth | float | 300 | Width of the timing track |
TrackHeight | float | 32 | Height of the timing track |
TrackColor | FLinearColor | Dark gray 50% | Background track color |
TargetZoneColor | FLinearColor | Green 60% | Target zone highlight color |
CursorColor | FLinearColor | White | Cursor line color |
CursorHitColor | FLinearColor | Green | Cursor color on successful hit |
CursorMissColor | FLinearColor | Red | Cursor color on miss |
BackgroundTint | FLinearColor | Black 60% | Background color |
Behavior
- OnChallengeProgressChanged: Updates cursor position by reading
GetCursorPosition()from the challenge; flashes cursor on hit/miss - OnChallengeCompleted: Stops cursor animation, shows success/failure state
- OnChallengeReset: Resets cursor to start position and default colors
BindWidget Names
TrackImage (Image), TargetZoneImage (Image), CursorImage (Image)
Quick Start (Custom Interaction Widget)
For custom interaction widgets, use the abstract base classes and implement in Blueprint:
Event BeginPlay
-> Create Widget (WBP_ERP_SinglePrompt, Owning Player: Self)
-> Add to Viewport
-> Get ERPInteractionComponent
-> Bind OnDescriptorChanged:
-> Widget -> UpdateFromDescriptor(Descriptor)
-> Bind OnDomainCandidateChanged:
-> Branch: NOT IsValid(New)
True: Widget already handles collapse via OnFocusChanged
The component calls SetFocused() automatically when focus changes — the widget's default OnFocusChanged toggles HitTestInvisible / Collapsed.
See the Widget Guide for full implementation patterns:
- Pattern 1: Single-Action Prompt
- Pattern 2: Multi-Action List (DirectKeys)
- Pattern 3: Action Wheel
- Pattern 4 & 5: Hold and Multi-Press Challenge sub-widgets
Summary
| Class | Type | Use Case |
|---|---|---|
UERPBaseTargetFrameWidget | Concrete | Target nameplate HUD |
UERPBaseTargetHealthBarWidget | Concrete | Target nameplate + health bar |
UERPBaseTargetReticleWidget | Concrete | World-space lock-on reticle |
UERPBaseMultiPressChallengeWidget | Concrete | "Mash [E]" press counter |
UERPBaseRadialHoldWidget | Concrete | Circular fill hold challenge |
UERPBaseWorldInteractionWidget | Concrete | World-space interaction prompt |
UERPBaseTimedPressChallengeWidget | Concrete | Countdown bar + key prompt (QTE) |
UERPBaseTimingChallengeWidget | Concrete | Track with cursor + target zone (QTE) |
UERPInteractionWidgetBase | Abstract base | Interaction prompt (implement in BP) |
UERPChallengeWidgetBase | Abstract base | Challenge feedback (implement in BP) |