Checking guarded tokens

NodeCanvas Forums Support Checking guarded tokens

Tagged: 

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #13449
    richard
    Participant

    Is there a way to check if a token is being guarded by a Guard node in a condition task? The desired behavior would be to prevent the decorated child from running if the token is being guarded, but not to actually guard the token itself.

    Thanks!

    #13452
    Gavalakis
    Keymaster

    Hello Richard!

    There is no way to check this, but considering that a branch in already guarded, why is there the need to check this again with a condition? 🙂
    Is the use case related to using along with Parallel Composite? Can you please share a screenshot of what you want to achieve more or less?
    I could add some option for this, but I just want to confirm the use case 🙂

    Thanks!

    Join us on Discord: https://discord.gg/97q2Rjh

    #13453
    richard
    Participant

    Yep, the use case in mind would be when a parallel composite is repeatedly run, and there are multiple child nodes which will guard if applicable, but otherwise there is a passive node which should be run when nothing is guarding.

    I’ve attached an example screenshot.

    Attachments:
    You must be logged in to view attached files.
    #13464
    Gavalakis
    Keymaster

    Hello again and sorry for the late reply due to summer vacation.

    Hmm.. I think that a Selector would be a better candidate for such “branching”. Have you considered using a Selector like this example instead, or
    is this totally outside the use case?
    Selector

    By the way, you don’t need to use a “Repeat” node as the root node, since the Behaviour Tree would already repeat automatically, if the “Repeat” option in enabled in the Behaviour Tree Owner inspector 🙂

    Please let me know.
    Thank you.

    Join us on Discord: https://discord.gg/97q2Rjh

    Attachments:
    You must be logged in to view attached files.
Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.