Blackboard – null GO bound parameter initialization error

NodeCanvas Forums General Discussion Blackboard – null GO bound parameter initialization error

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #17900
    bombonito
    Participant

    I am doing an AI of a rat that should patrol the area and look for food.
    I created a Global Blackboard, added Game Object BBParameter for the current food target, bound it to a GameObject property in my script.
    I intend to leave it as null (by default rat has no idea that any food exists, and has to find it later)
    Inside the AI I have Seek node for NavMeshAgent
    During scene startup, inside InitializeFieldAttributes() method on Seek node, I get an error that ‘target’ is null and the variable will not be initialized.
    And later ActionTask is ignored because it has ‘_isInitSuccess’ = false (or the whole tree has _isInitSuccess = false, not sure how that works)

    Why is it an error, shouldn’t it be a warning? And is there any option to disable those validations?
    Also, all those validations are in #if UNITY_EDITOR group, so they will not affect the build, it just doesn’t let me test in editor, I assume.

    P.S. I tested this without bound parameter, just null GO as exposed property, works with no problem

    Attachments:
    You must be logged in to view attached files.
    #17912
    bombonito
    Participant

    Managed to solve the problem.
    After some more debugging and help from my friend 🙂
    ‘Check boolean’ node is giving wrong results when trying to do GameObject == true/false.
    I’m now using Inverter + Check Variable (GameObject), and the result is correct.

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