How do I check a UnityEvent?

NodeCanvas Forums Support How do I check a UnityEvent?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #12824
    kurasu1415
    Participant

    Is there a way to check for a UnityEvent in a Conditional inside a BehaviorTree? I simply want to interrupt a child immediately if an event is thrown. I have also tried using C# Events, but NodeCanvas can’t seem to find my Action.

    #12825
    kurasu1415
    Participant

    Actually, I had to update to see UnityEvents as an option, but it doesn’t seem to see my public UnityEvents at all? Is there something special I need to do?

    #12829
    Gavalakis
    Keymaster

    Hello,

    There are the “CheckUnityEvent” and “CheckUnityEvent(T)” Condition Tasks which you can use to check Unity Events. At the moment only UnityEvents with no, or one argument are supported.

    If your event has no argument, you will need to use the “CheckUnityEvent” condition, whereas if your event has 1 argument, you will need to use the “CheckUnityEvent(T)” condition, where T would be the type of your event’s argument.

    Thus, you will first need to assign the correct condition of the two to use in your node you want, and then from within the inspector for the condition, hit the “Select Event” button, which will popup a menu with all possible events that can be selected.

    Please let me know if the above works for you, or if you are still facing any issues.
    Thank you.

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

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