How to make a node 'Wait Until Something'?

NodeCanvas Forums Support How to make a node 'Wait Until Something'?

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #9910

    I want make a node, it is keep running state until it’s condition property is true.
    Any idea?

    #9914

    I made this. But not working.

    #9913
    Gavalakis
    Keymaster

    Hello,

    You can replicate what you are after with a Repeater Decorator and an Accessor Decorator underneath.
    For this you should set the Repeater in “Repeat Until Success”.
    So the Repeater will repeat the child node (Accessor) until it returns Success.

    You could certainly create a single node that does that. Let me know if you want such a node.

    Is that what you are after?

    Cheers

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

    #9912

    In my battle scene, be a game controller and some roles, they all based on NC.
    Game controller need to call roles to do something and need to know when it finished. So it is need a node “Wait Until Condition”.
    I built a node like upper replay, has a event string property.If the event is ture return success else run forever.
    It works well like follow photo.

    #9911
    Gavalakis
    Keymaster

    Hello,

    Nice 🙂
    So it’s more of a wait event action task.

    You could also make a specialized node (not task) that can be assigned a condition and that node return Running until the assigned condition returns true, os it could be more flexible as of what condition it waits for.

    Let me know if you need something like that.

    Cheers!

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

    #11517
    chocolacode
    Participant

    Hey Gavalakis,

    I am looking exactly for a Decorator like Wait Until Condition” and found this thread,

    What do you mean by “child node (Accessor) “,

    Can you show your above suggestion in a screenshot example? or can you provide such a node in code?

    thanks in advance!

    #11524
    Gavalakis
    Keymaster

    Hey!

    There is already a Decorator called “Wait Until” (waits until the condition becomes true), which was non-existent when this thread was started 🙂 It’s the last one in the Decorators menu. You can use it instead of the suggestion posted above.

    “Accessor” Decorator, was the name of the now named “Conditional Decorator” at the time of this threat.
    So Accessor Decorator = Conditional Decorator 🙂

    Let me know if the ‘Wait Until’ Decorator works for you.
    Cheers!

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

    #11533
    chocolacode
    Participant

    Hey,

    that explains everything!!

    thanks! 🙂

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.