Page 1 of 1

While deserializing quest tags, found a tag with a blank name in Start.

Posted: Fri Mar 27, 2020 5:11 am
by thaptam
Hi Tony Li,

I'm making the loading for my game and get the issue. My progress: get all the data from the journal and save it to the JSON file. Load JSON file and use ApplyData to the journal. I'm not sure what's wrong with the tag because I only use the internal name of the quest state. This issue stops me from continuing to play my quest. Here is the log file for debug:

Quest Machine: While deserializing quest tags, found a tag with a blank name in Start.
UnityEngine.Debug:LogWarning(Object)
PixelCrushers.QuestMachine.QuestStateSerializer:ReadTagDictionaryFromStream(BinaryReader, TagDictionary, String) (at Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Quest/Quest Serialization/QuestStateSerializer.cs:201)
PixelCrushers.QuestMachine.QuestStateSerializer:ReadQuestNodeDataFromStream(BinaryReader, QuestNode) (at Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Quest/Quest Serialization/QuestStateSerializer.cs:182)
PixelCrushers.QuestMachine.QuestStateSerializer:ReadQuestDataFromStream(BinaryReader, Quest) (at Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Quest/Quest Serialization/QuestStateSerializer.cs:170)
PixelCrushers.QuestMachine.QuestStateSerializer:DeserializeInto(Quest, Byte[], Boolean) (at Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Quest/Quest Serialization/QuestStateSerializer.cs:59)
PixelCrushers.QuestMachine.QuestListContainer:ApplyData(String) (at Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Quest MonoBehaviours/Quest List/QuestListContainer.cs:361)
PixelCrushers.QuestMachine.QuestJournal:ApplyData(String) (at Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Quest MonoBehaviours/Quest List/QuestJournal.cs:174)
ThapTam.Game.<Loading>d__18:MoveNext() (at Assets/MAIN/Scripts/Controller/PlayerController.cs:183)

Re: While deserializing quest tags, found a tag with a blank name in Start.

Posted: Fri Mar 27, 2020 1:01 pm
by Tony Li
Hi,

Does Quest Machine's built-in save system work correctly with your quest(s)?

If so, then as a test try serializing your quest and then immediately deserializing it. Or call string s = QuestJournal.RecordData(), then immediately call QuestJournal.ApplyData(s).

Re: While deserializing quest tags, found a tag with a blank name in Start.

Posted: Tue Mar 31, 2020 11:40 pm
by thaptam
The built-in save system worked normally when I updated the version of Unity from 2019.2.06f to 2019.2.21f1.

Re: While deserializing quest tags, found a tag with a blank name in Start.

Posted: Wed Apr 01, 2020 7:48 am
by Tony Li
Hmm, I wonder if a file got corrupted in your previous install or something like that. Is saving and loading working in your game now?

Re: While deserializing quest tags, found a tag with a blank name in Start.

Posted: Thu Apr 09, 2020 11:52 pm
by thaptam
From what I remember, that issue usually happened during the time I tested the game after modifying a quest. Example steps:
1. Design a quest
2. Test it and save that
3. Back to edit that quest
4. Open the game and load that saved file. <= this time the issue happens

Re: While deserializing quest tags, found a tag with a blank name in Start.

Posted: Fri Apr 10, 2020 8:20 am
by Tony Li
Thanks for those reproduction steps. I'll experiment with reproducing it using those steps. The next version shouldn't report the error anyway, since it should automatically take care of it.