UBehaviorTreeComponent::ScheduleNextTick
#include "BehaviorTree/BehaviorTreeComponent.h"
Access: public
Description
Requests when the behavior tree component should next process a full tick, letting the tree throttle its own update frequency instead of always running every frame.
Caveats & Gotchas
- • Passing FLT_MAX effectively disables ticking until something else (e.g. a new execution request) schedules a nearer tick.
- • Multiple calls in the same frame take the smallest requested delta, so one node requesting a fast tick overrides another requesting a slow one.
- • This affects the whole component's tick cadence, not just the calling node — it's a shared scheduling resource across all active nodes.
Signature
void ScheduleNextTick(float NextDeltaTime); Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| NextDeltaTime | float | Delay before the next tick; 0.0f means next frame, FLT_MAX means never. | — |
Return Type
void Example
Throttle tree ticking to twice a second C++
void UMyTask::TickTask(UBehaviorTreeComponent& OwnerComp, uint8* NodeMemory, float DeltaSeconds)
{
OwnerComp.ScheduleNextTick(0.5f);
} Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?