> 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-manager-component/methods.md).

# Methods

### Static Helpers

#### `GetComponent`

```cpp
static UIndicatorManagerComponent* GetComponent(AActor* Actor);
```

Searches `Actor` for an attached `UIndicatorManagerComponent` and returns it, or `nullptr` if none is found. Equivalent to `Actor->FindComponentByClass<UIndicatorManagerComponent>()`, but null-safe.

**Example:**

```cpp
if (UIndicatorManagerComponent* IMC = UIndicatorManagerComponent::GetComponent(SomeActor))
{
    // actor has an active indicator
}
```

***

### Instance Methods

#### `AddIndicator`

```cpp
UFUNCTION(BlueprintCallable, Category = Indicator)
void AddIndicator(UIndicatorDescriptor* IndicatorDescriptor);
```

Manually registers an additional `UIndicatorDescriptor` with this component. The method:

* Sets the descriptor's back-pointer (`SetIndicatorManagerComponent(this)`).
* Appends it to the internal `Indicators` array.
* Broadcasts `OnIndicatorAdded`.

Useful when you need **more than one indicator** on the same actor (e.g., a health bar *and* a nameplate above the same character).

> The descriptor created automatically by `BeginPlay` is already registered via this method. You do **not** need to call it for the default descriptor.

#### `RemoveIndicator`

```cpp
UFUNCTION(BlueprintCallable, Category = Indicator)
void RemoveIndicator(UIndicatorDescriptor* IndicatorDescriptor);
```

Unregisters and removes a descriptor from the component, broadcasting `OnIndicatorRemoved`. An `ensure` checks that the descriptor belongs to this component before removal.

#### `GetIndicators`

```cpp
const TArray<UIndicatorDescriptor*>& GetIndicators() const;
```

Returns a read-only reference to all currently registered descriptors. C++ only; use the events to observe additions/removals rather than polling this array every frame.

***
