Issue: Behaviour Tree gone (canvas empty)

Forums 💬 NodeCanvas ⚙️ Support Issue: Behaviour Tree gone (canvas empty)

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #18807
    jonc
    Participant

      Hi,

      I accidentally declared a Blackboard variable inside a custom condition class like this (my bad):

      [RequiredField]
      public T typeToCheck;

      Which leads to following error and the permanent(?) deletion of the behaviour tree inside the canvas:

      Deserialization Error: ‘Type doesn’t have a parameter less constructor’
      ‘ at System.Linq.Expressions.Expression.New (System.Type type) [0x00000] in <filename unknown>:0
      at ParadoxNotion.Serialization.FullSerializer.fsMetaType..ctor (System.Type reflectedType) [0x00050] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerReflectionfsMetaType.cs:41
      at ParadoxNotion.Serialization.FullSerializer.fsMetaType.Get (System.Type type) [0x00012] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerReflectionfsMetaType.cs:18
      at ParadoxNotion.Serialization.FullSerializer.Internal.fsReflectedConverter.CreateInstance (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType) [0x00000] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerConvertersfsReflectedConverter.cs:88
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_3_Inheritance (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List1& processors) [0x000df] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:777
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_1_CycleReference (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List
      1& processors) [0x0003f] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:689
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result) [0x00038] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:659
      at ParadoxNotion.Serialization.FullSerializer.Internal.fsReflectedConverter.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Object& instance, System.Type storageType) [0x00085] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerConvertersfsReflectedConverter.cs:76
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_5_Converter (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type resultType, System.Object& result) [0x00012] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:821
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_4_Cycles (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type resultType, System.Object& result) [0x00029] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:812
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_3_Inheritance (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List1& processors) [0x000fc] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:790
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_1_CycleReference (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List
      1& processors) [0x0003f] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:689
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result) [0x00038] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:659
      at ParadoxNotion.Serialization.FullSerializer.Internal.fsIEnumerableConverter.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Object& instance_, System.Type storageType) [0x0006a] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerConvertersfsIEnumerableConverter.cs:69
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_5_Converter (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type resultType, System.Object& result) [0x00012] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:821
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_4_Cycles (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type resultType, System.Object& result) [0x00029] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:812
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_3_Inheritance (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List1& processors) [0x000fc] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:790
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_1_CycleReference (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List
      1& processors) [0x0003f] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:689
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result) [0x00038] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:659
      at ParadoxNotion.Serialization.FullSerializer.Internal.fsReflectedConverter.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Object& instance, System.Type storageType) [0x00085] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerConvertersfsReflectedConverter.cs:76
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_5_Converter (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type resultType, System.Object& result) [0x00012] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:821
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_4_Cycles (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type resultType, System.Object& result) [0x00029] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:812
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_3_Inheritance (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List1& processors) [0x000fc] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:790
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.InternalDeserialize_1_CycleReference (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result, System.Collections.Generic.List
      1& processors) [0x0003f] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:689
      at ParadoxNotion.Serialization.FullSerializer.fsSerializer.TryDeserialize (ParadoxNotion.Serialization.FullSerializer.fsData data, System.Type storageType, System.Object& result) [0x00038] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationFullSerializerfsSerializer.cs:659
      at ParadoxNotion.Serialization.JSONSerializer.Deserialize (System.Type type, System.String serializedState, System.Collections.Generic.List1 objectReferences) [0x00066] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationJSONSerializer.cs:78
      at ParadoxNotion.Serialization.JSONSerializer.Deserialize[GraphSerializationData] (System.String serializedState, System.Collections.Generic.List
      1 objectReferences) [0x00000] in NodeCanvasFramework_ParadoxNotion (shared)RuntimeSerializationJSONSerializer.cs:48
      at NodeCanvas.Framework.Graph.Deserialize (System.String serializedGraph, Boolean validate, System.Collections.Generic.List1 objectReferences) [0x0001b] in NodeCanvasFrameworkRuntimeGraphsGraph.cs:102 ‘

      <b>Please report bug</b>
      UnityEngine.Debug:LogError(Object, Object)
      NodeCanvas.Framework.Graph:Deserialize(String, Boolean, List
      1) (at Assets/NodeCanvas/Framework/Runtime/Graphs/Graph.cs:113)
      NodeCanvas.Framework.Graph:OnAfterDeserialize() (at Assets/NodeCanvas/Framework/Runtime/Graphs/Graph.cs:54)

      #18811
      Gavalakis
      Keymaster

        Hey,

        This is a bug that has been fixed now. Let me know of an email and I will send you the new version through. Sorry about this.
        Regarding recovering the graph from this bug, exporting it to json through the menu should give the original serialized graph data, which we can change to fix it. Does the json file has any data within in your case?

        Thanks

        #18810
        jonc
        Participant

          Hi Gavalakis,

          thanks for dropping by. Sorry, I don’t understand what you mean by the data inside json file, I just know: I can load json files without a problem, but I haven’t tried to export and reload it while it’s in the broken empty state, if you mean that. I will try this, if it ever happens again.

          I already reported a similar bug via email (grandsilence@ -> “serious bug”), imported it into one of my projects but then forgot to import it into the one I’m working on now, silly me. :-S

          Regarding your offer, does this new version already contain the option for fixed “one line” connections? I’m eager to try this out!

          #18809
          Gavalakis
          Keymaster

            Hey,

            What I ment before, was that if this ever happens again, you can try exporting the visualy empty graph to a json file. Then you could open up the json file and fix the thing that causes the issue from there (or send it over to me so that I do so) and then reimport the json back to the graph.
            With the new version though, this problem should not occur again hopefuly.

            The new version doesn’t yet has the “one line” connection style, but rather only the straight lines one. This will come a bit later on. Sorry 🙂 I’ve already submited this version to the asset store, but if you want it sooner, let me know of an email.

            Also, what “other bug” do you refer to? 🙂

            Thanks!

            #18808
            jonc
            Participant

              Oops, the sentence wasn’t complete. Nevermind, it was the same bug and you already sent me a fixed version of NC, which I in return forgot to import into all of my projects, thus I was thinking it’s an issue with the fixed version. But at least now I know of a way to recover a tree, just in case this or something of the kind happens again.

              I’d actually be happy to grab a copy of the new version a little bit sooner. I’ll send you an email. Thank you!

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