[BUG] Disabling NavMeshAgent causes error spam

NodeCanvas Forums Support [BUG] Disabling NavMeshAgent causes error spam

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #15645
    covis
    Participant

    Disabling NavMeshAgent component causes error spam when NodeCanvas graph inspector window is open.

    NodeCanvas v3.20
    Unity 2020.3.5f1

    Repro steps:

    1. Create GO with NavMeshAgent and FSM owner and bake NavMesh on a plane.
    2. Bind any NavMeshAgent property to blackboard.
    3. Create setup like in the picture (important to have atleast 1 task has the bound property used.)
    4. Press play and disable NavMeshAgent component.
    5. Get spammed by this error as long as u have graph inspector open and focused.

    “IsStopped” can only be called on an active agent that has been placed on a NavMesh.
    UnityEngine.StackTraceUtility:ExtractStackTrace ()

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

    Hello,

    You are right. It is a small bug related to task warnings. To fix this, please open up Task.cs file and replace the whole “GetWarningsOrError” method with the code bellow:

    Only line #36 (as shown in above code lines) is changed actually, but I copy/pasted the whole method for your convenience.
    Let me know if that works for you.
    Thanks!

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

    #15668
    covis
    Participant

    This does fix the issue allowing to view graph inspector without getting spam. However if u happen to select state node that has these variables in use same problem still persists.

    #15679
    Gavalakis
    Keymaster

    Hello again,
    You are right. Please open up BBParameterEditor.cs and change line #78 to the following:
    if ( required && !string.IsNullOrEmpty(bbParam.name) && !bbParam.isDefined && bbParam.isNull ) { EditorUtils.MarkLastFieldWarning("An instance is required but currently resolves to null. If it is set in runtime you can ignore this warning."); }

    Thanks 🙂

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

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