I Need Advice with Custom Action Task for NodeCanvas Behavior Trees

NodeCanvas Forums General Discussion I Need Advice with Custom Action Task for NodeCanvas Behavior Trees

Tagged: 

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #17965
    chiravlo
    Participant

    Hello there,

    I have been working with NodeCanvas for a while now and really enjoying its flexibility; but I have hit a roadblock that I could use some help with. I am trying to create a custom action task to use in my behavior trees; but I am having trouble figuring out how to properly structure the code to make it work the way I want.

    The action task I am aiming to create should make the AI character perform a specific animation and then wait for the animation to complete before moving on to the next node in the behavior tree. I understand how to trigger animations through Unity’s Animator component; but I am not sure how to handle the waiting part efficiently within the action task.

    Set up a coroutine or other method to handle waiting for the animation to finish.
    Ensure the action task properly returns success or failure based on the completion of the animation.

    Also, I have gone through your post; https://forum.unity.com/threads/nodecanvas-behaviour-trees-state-machines-dialogue-blue-prism-trees.227190/page-35 which definitely helped me out a lot.

    Implement this in a way that does not block the entire behavior tree during the animation playback

    Thanks in advance for your help and assistance.

Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.