UMageItCombatTextRendererBase
Base Class: UObject
Overview
Section titled “Overview”UMageItCombatTextRendererBase is the abstract contract every renderer backend implements. It is Abstract,
Blueprintable, and EditInlineNew, so you can write an entirely new rendering backend as a Blueprint or C++
subclass and register it in UMageItCombatTextSettings::RendererRegistry just like the three
built-in renderers (UMG, Niagara, Slate).
An instance is created lazily by UMageItCombatTextSubsystem::GetRenderer the first time a
FGameplayTag resolves to its class, and lives for the lifetime of the local player.
Properties (Variables)
Section titled “Properties (Variables)”CombatTextSubsystem(ULocalPlayerSubsystem*,BlueprintReadOnly): The owning subsystem, cached duringInitialize.PlayerController(APlayerController*,BlueprintReadOnly): The local player’s controller, resolved fromCombatTextSubsystem’sULocalPlayer. SeeResolvePlayerControllerbelow — this isn’t a one-time lookup.
Internal Helpers (C++ Only)
Section titled “Internal Helpers (C++ Only)”ResolvePlayerController(): Re-resolvesPlayerControllerfromCombatTextSubsystem’sULocalPlayerwhenever it’s currently null or invalid, and returns it.Initializecalls this once, but the controller doesn’t survive level travel the way the local player and this renderer instance do, so the built-in renderers (UMG/Niagara/Slate) all call it again at the top of everyTickinstead of trusting the cached pointer.CanTick() const: ReturnsfalseonceShutdownhas run, or when called on the class default object or an editor archetype (whichFTickableGameObjectalso registers, but which should never tick). The built-in tickable renderers return this directly from theirFTickableGameObject::IsTickable()override, so the engine stops callingTickon them entirely rather than relying on an early-out insideTickitself.
Lifecycle (Blueprint Native Events)
Section titled “Lifecycle (Blueprint Native Events)”Initialize
Section titled “Initialize”void Initialize(ULocalPlayerSubsystem* OwningSubsystem);Called once, the first time the subsystem lazily creates this renderer. The base implementation caches
CombatTextSubsystem, resolves PlayerController, and clears the bShutDown flag — so calling Initialize again
on an already shut-down instance makes it tickable again. Always call the parent implementation first when
overriding.
RenderDamage
Section titled “RenderDamage”void RenderDamage(const FMageItCombatTextEvent& EventData);Called for every event routed to this renderer by AddDamageEvent. The base implementation is a
no-op — concrete renderers override this to actually spawn or update visuals.
Shutdown
Section titled “Shutdown”void Shutdown();Called when the owning subsystem is deinitialized (see UMageItCombatTextSubsystem::Deinitialize).
The base implementation sets an internal bShutDown flag (see CanTick below) so a tickable renderer stops ticking
even if garbage collection hasn’t destroyed it yet — concrete renderers override Shutdown on top of this to
release widgets, Niagara components, or Slate content, and should call the parent implementation.
GetWorld Override
Section titled “GetWorld Override”virtual UWorld* GetWorld() const override;Since renderer instances are plain UObjects (not Actors or Components), GetWorld() is overridden to resolve the
world through the renderer’s Outer (the owning subsystem). Returns nullptr for the class default object.