pub struct BehaviorTree { /* private fields */ }Expand description
A behavior tree that can be executed with a context
Implementations§
Source§impl BehaviorTree
impl BehaviorTree
Sourcepub fn tick(&mut self, context: &TreeContext) -> Result<NodeResult>
pub fn tick(&mut self, context: &TreeContext) -> Result<NodeResult>
Execute one tick of the behavior tree
Sourcepub fn tick_with_delta(
&mut self,
context: &TreeContext,
delta_time: f64,
) -> Result<NodeResult>
pub fn tick_with_delta( &mut self, context: &TreeContext, delta_time: f64, ) -> Result<NodeResult>
Execute one tick of the behavior tree with delta time
Sourcepub fn is_running(&self) -> bool
pub fn is_running(&self) -> bool
Check if the tree is currently running
Auto Trait Implementations§
impl Freeze for BehaviorTree
impl RefUnwindSafe for BehaviorTree
impl Send for BehaviorTree
impl Sync for BehaviorTree
impl Unpin for BehaviorTree
impl UnsafeUnpin for BehaviorTree
impl UnwindSafe for BehaviorTree
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more