Skip to content

how to keep composite node retick running child? #13

Answered by linkdd
benloong asked this question in Q&A
Discussion options

You must be logged in to vote

Let's say I have a CharacterController state machine with the following states:

  • Idle
  • Moving Towards Enemy
  • Attack Enemy

And a Behavior Tree composed of the following nodes:

  • Sequence:
    • Check: If Enemy in field of view, then SUCCESS, else FAILURE
    • Task: Transition CharacterController to state Moving Towards Enemy, then SUCCESS
    • Check: If Enemy in attack range, then SUCCESS, else RUNNING
    • Task: Transition CharacterController to state Attack Enemy, then RUNNING

Now, an enemy comes into the field of view, so the first check succeeds, which means the task is executed, which change the state machine's state. The enemy is not yet in attack range, so the second check is still RUNNING, therefore …

Replies: 2 comments 4 replies

Comment options

You must be logged in to vote
4 replies
@linkdd
Comment options

@linkdd
Comment options

@benloong
Comment options

@linkdd
Comment options

Answer selected by benloong
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #12 on March 13, 2024 01:00.