UBlackboardComponent::UninitializeComponent
#include "BehaviorTree/BlackboardComponent.h"
Access: public
Specifiers: virtualoverride
Description
Overrides UActorComponent::UninitializeComponent to tear down the blackboard's allocated key values and release observers when the component is uninitialized.
Caveats & Gotchas
- • Frees the internal ValueMemory block and destroys instanced key data, so any raw pointers previously obtained via GetKeyRawData become invalid after this runs.
- • Runs as part of the standard actor component teardown flow, which normally happens on EndPlay/destruction — you rarely need to call it manually.
- • Registered observers are not guaranteed to receive a final notification during teardown, so don't rely on observer callbacks to clean up external state at end of life.
Signature
virtual void UninitializeComponent() override Return Type
void Example
Automatic teardown on component destruction C++
// UninitializeComponent() is invoked by the engine as part of actor/component teardown
// No manual call needed in typical gameplay code Tags
Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?