> For the complete documentation index, see [llms.txt](https://dante-3.gitbook.io/dante-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dante-3.gitbook.io/dante-docs/indicator-system-plugin/indicator-descriptor/targeting-properties.md).

# Targeting Properties

These control what the indicator tracks in the world.

### `DataObject`

```cpp
UObject* GetDataObject() const;
void SetDataObject(UObject* InDataObject);
```

An arbitrary `UObject` payload passed directly to the indicator widget. The widget can cast this to the expected type (e.g., the owning actor, a game component, a data struct wrapper). Implement `IActorIndicatorWidget` on your widget to receive this automatically.

### `SceneComponent`

```cpp
USceneComponent* GetSceneComponent() const;
void SetSceneComponent(USceneComponent* InComponent);
```

The world-space source component used for projection. The indicator's screen position is derived from this component's location (or bounding box, depending on projection mode).

* Set to `UCapsuleComponent` for `ACharacter` actors by `UIndicatorManagerComponent`.
* Set to `RootComponent` for all other actors.
* Setting this to `nullptr` will cause `GetIsVisible()` to return `false` and, if `bAutoRemoveWhenIndicatorComponentIsNull` is enabled, the indicator will be removed automatically.

### `ComponentSocketName`

```cpp
FName GetComponentSocketName() const;
void SetComponentSocketName(FName SocketName);
```

Optional socket on `SceneComponent` to use as the world-space origin instead of the component's pivot. Defaults to `NAME_None` (pivot is used).

### `IndicatorClass`

```cpp
TSoftClassPtr<UUserWidget> GetIndicatorClass() const;
void SetIndicatorClass(TSoftClassPtr<UUserWidget> InIndicatorWidgetClass);
```

The `UUserWidget` subclass to spawn and display for this indicator. This is a soft class reference — the asset is loaded asynchronously when the indicator becomes active.

> Set this with a setup action (`IndicatorAction_IndicatorClass`) rather than directly when using the data-driven workflow.

***

## Visibility Properties

### `GetIsVisible` / `SetDesiredVisibility`

```cpp
bool GetIsVisible() const;
void SetDesiredVisibility(bool InVisible);
```

`GetIsVisible()` returns `true` only when **both** conditions hold:

1. `SceneComponent` is a valid (non-null, non-pending-kill) object.
2. The internal `bVisible` flag is `true`.

Use `SetDesiredVisibility(false)` to temporarily hide an indicator without destroying it.

### `MaxVisibleDistance` / `MinVisibleDistance`

```cpp
float GetMaxVisibleDistance() const;   void SetMaxVisibleDistance(float InDistance);
float GetMinVisibleDistance() const;   void SetMinVisibleDistance(float InDistance);
```

Distance-based culling in **centimeters** (Unreal units).

| Value                    | Behavior                                  |
| ------------------------ | ----------------------------------------- |
| `MaxVisibleDistance = 0` | No maximum — visible at any distance      |
| `MinVisibleDistance = 0` | No minimum — visible even when very close |

***

## Projection Properties

### `ProjectionMode`

```cpp
EActorCanvasProjectionMode GetProjectionMode() const;
void SetProjectionMode(EActorCanvasProjectionMode InProjectionMode);
```

Controls how the 3D world position is mapped to a 2D screen coordinate. See [EActorCanvasProjectionMode](#eactorcanvasprojectionmode) below.

### `WorldPositionOffset`

```cpp
FVector GetWorldPositionOffset() const;
void SetWorldPositionOffset(FVector Offset);
```

An offset applied to the resolved world position **before** projection. Use this to raise an indicator above a character's head without changing the actual scene component.

```cpp
// Raise 90 cm above the component pivot
Desc->SetWorldPositionOffset(FVector(0, 0, 90));
```

### `ScreenSpaceOffset`

```cpp
FVector2D GetScreenSpaceOffset() const;
void SetScreenSpaceOffset(FVector2D Offset);
```

A pixel offset applied **after** projection. The X component is flipped when the target is behind the camera.

### `BoundingBoxAnchor`

```cpp
FVector GetBoundingBoxAnchor() const;
void SetBoundingBoxAnchor(FVector InBoundingBoxAnchor);
```

A normalized `(0–1, 0–1, 0–1)` anchor within the bounding box used only by bounding-box projection modes. Default is `(0.5, 0.5, 0.5)` (center). Set to `(0.5, 0.5, 1.0)` to anchor at the top of the bounding box.

***

## Alignment Properties

### `HAlign` / `VAlign`

```cpp
EHorizontalAlignment GetHAlign() const;   void SetHAlign(EHorizontalAlignment InHAlignment);
EVerticalAlignment   GetVAlign() const;   void SetVAlign(EVerticalAlignment InVAlignment);
```

Alignment of the widget **relative to the projected screen point**. Controls which part of the widget sits at the computed position.

| Value                     | Meaning                                      |
| ------------------------- | -------------------------------------------- |
| `HAlign_Center` (default) | Widget is horizontally centered on the point |
| `HAlign_Left`             | Widget's left edge is at the point           |
| `HAlign_Right`            | Widget's right edge is at the point          |
| `VAlign_Center` (default) | Widget is vertically centered on the point   |
| `VAlign_Top`              | Widget's top edge is at the point            |
| `VAlign_Bottom`           | Widget's bottom edge is at the point         |

***

## Screen-Edge Clamping

When the indicator's world target is outside the camera's frustum, clamping locks the widget to the nearest screen edge.

### `ClampToScreen`

```cpp
bool GetClampToScreen() const;
void SetClampToScreen(bool bValue);
```

Enables screen-edge clamping. Default: `false`.

### `ShowClampToScreenArrow`

```cpp
bool GetShowClampToScreenArrow() const;
void SetShowClampToScreenArrow(bool bValue);
```

When `true`, shows a directional arrow widget pointing toward the off-screen target while the indicator is clamped. Default: `false`.

### `ArrowBrush`

```cpp
FSlateBrush GetArrowBrush() const;
void SetArrowBrush(FSlateBrush InArrowBrush);
```

The `FSlateBrush` used to render the directional arrow. Typically set via the `IndicatorAction_ArrowStyle` setup action.

***

## Size & Scale Properties

### `OverrideDesiredSize` / `DesiredSize`

```cpp
bool     GetOverrideDesiredSize() const;   void SetOverrideDesiredSize(bool bOverride);
FVector2D GetDesiredSize() const;           void SetDesiredSize(FVector2D InSize);
```

When `bOverrideDesiredSize` is `true`, the widget is forced to render at `DesiredSize` (pixels) instead of its natural desired size. Default size is `(100, 100)`.

### `Scale`

```cpp
float GetScale() const;
void SetScale(float InScale);
```

Uniform scale multiplier applied to the widget. Default: `1.0`.

### `Scale2D`

```cpp
FVector2D GetScale2D() const;
void SetScale2D(FVector2D InScale2D);
```

Per-axis scale applied independently on X and Y. Default: `(1.0, 1.0)`. Applied in addition to `Scale`.

***

## Sorting & Overlap Properties

### `Priority`

```cpp
int32 GetPriority() const;
void SetPriority(int32 InPriority);
```

Render order within the same depth bucket. Higher values are drawn on top. Default: `0`.

### `PreventOverlap` / `OverlapPadding`

```cpp
bool      GetPreventOverlap() const;   void SetPreventOverlap(bool bPrevent);
FVector2D GetOverlapPadding() const;   void SetOverlapPadding(FVector2D InPadding);
```

When `bPreventOverlap` is `true`, the canvas offsets this indicator to avoid drawing on top of already-placed indicators. `OverlapPadding` adds extra pixel clearance around the widget bounds during overlap detection. Default padding: `(5, 5)`.

***
