* add SaveSystem Prefab to Dialogue Manager
* add DialogSystemSaver Component to Dialogue Manager and set it as described in Tony's last posting here: https://www.pixelcrushers.com/phpbb/vie ... f=3&t=4566
* added a "load" and "save" button to the UI that simply call the SaveSystem Load/SaveSceneFromIndex(1)
The error is the same as in my game:
Code: Select all
Dialogue System: Lua code 'Variable={Alert="", Actor="Player", Conversant="Story", ActorIndex="Player", ConversantIndex="Story", wagerAmount=0, forceful=0, evasive=0, teacup=0, gotcomponent=0, drugged=0, hooper_mentioned=0, losttemper=0, admitblackmail=0, hooperClueType=0, hooperConfessed=0, smashingWindowItem=0, notraitor=0, revealedhooperasculprit=0, smashedglass=0, muddyshoes=0, framedhooper=0, putcomponentintent=0, throwncomponentaway=0, piecereturned=0, longgrasshooperframe=0, DEBUG=0, Story_story="{\"flows\":{\"DEFAULT_FLOW\":{\"callstack\":{\"threads\":[{\"callstack\":[{\"cPath\":\"\",\"idx\":0,\"exp\":false,\"type\":0}],\"threadIndex\":0}],\"threadCounter\":0},\"outputStream\":[],\"currentChoices\":[]}},\"currentFlowName\":\"DEFAULT_FLOW\",\"variablesState\":{},\"evalStack\":[],\"visitCounts\":{\"\":1},\"turnIndices\":{},\"turnIdx\":-1,\"storySeed\":95,\"previousRandom\":0,\"inkSaveVersion\":9,\"inkFormatVersion\":20}", Story_TheIntercept="{\"flows\":{\"DEFAULT_FLOW\":{\"callstack\":{\"threads\":[{\"callstack\":[{\"exp\":false,\"type\":0,\"temp\":{\"$r\":{\"^->\":\"start.waited.0.g-0.5.$r1\"}}}],\"threadIndex\":6,\"previousContentObject\":\"start.waited.0.g-0.11\"}],\"threadCounter\":9},\"outputStream\":[\"^\\"Well, then,\\" he begins, awkwardly. This is an unseemly situation.\",\"\n\"],\"choiceThreads\":{\"7\":{\"callstack\":[{\"cPath\":\"start.waited.0.g-0.4\",\"idx\":8,\"exp\":false,\"type\":0,\"temp\":{\"$r\":{\"^->\":\"start.waited.0.g-0.4.$r1\"}}}],\"threadIndex\":7,\"previousContentObject\":\"start.waited.0.g-0.4.7\"},\"8\":{\"callstack\":[{\"cPath\":\"start.waited.0.g-0.5\",\"idx\":10,\"exp\":false,\"type\":0,\"temp\":{\"$r\":{\"^->\":\"start.waited.0.g-0.5.$r1\"}}}],\"threadIndex\":8,\"previousContentObject\":\"start.waited.0.g-0.5.9\"},\"9\":{\"callstack\":[{\"cPath\":\"start.waited.0.g-0\",\"idx\":11,\"exp\":false,\"type\":0,\"temp\":{\"$r\":{\"^->\":\"start.waited.0.g-0.5.$r1\"}}}],\"threadIndex\":9,\"previousContentObject\":\"start.waited.0.g-0.10\"}},\"currentChoices\":[{\"text\":\"\\"Commander.\\"\",\"index\":0,\"originalChoicePath\":\"start.waited.0.g-0.4.8\",\"originalThreadIndex\":7,\"targetPath\":\"start.waited.0.g-0.c-0\"},{\"text\":\"\\"Tell me what this is about.\\"\",\"index\":1,\"originalChoicePath\":\"start.waited.0.g-0.5.10\",\"originalThreadIndex\":8,\"targetPath\":\"start.waited.0.g-0.c-1\"},{\"text\":\"Wait\",\"index\":2,\"originalChoicePath\":\"start.waited.0.g-0.11\",\"originalThreadIndex\":9,\"targetPath\":\"start.waited.0.g-0.c-2\"}]}},\"currentFlowName\":\"DEFAULT_FLOW\",\"variablesState\":{},\"evalStack\":[],\"visitCounts\":{\"\":1,\"start\":1,\"start.0.g-0\":1,\"start.0.g-0.c-0\":1,\"start.0.opts\":2,\"start.0.opts.0\":2,\"start.0.opts.c-1\":1,\"start.0.opts.c-3\":1,\"start.0.g-1\":1,\"start.waited\":1,\"start.waited.0.g-0\":1},\"turnIndices\":{},\"turnIdx\":2,\"storySeed\":69,\"previousRandom\":0,\"inkSaveVersion\":9,\"inkFormatVersion\":20}", CurrentStory="TheIntercept", WasPlayerSpeaking=false}; Item["The_Wager"].State="unassigned"; Item["The_Wager"].Track=true; Actor={Player={Name="Player", Pictures="[]", Description="", IsPlayer=true, Bark_Index=0}, Story={Name="Story", Pictures="[]", Description="", IsPlayer=false}, PlayerSpeaker={Name="PlayerSpeaker", Pictures="[]", Description="", IsPlayer=false, Display_Name="Player"}, Monsieur_Fogg={Name="Monsieur Fogg", Pictures="[]", Description="", IsPlayer=false}}; StatusTable = ""; RelationshipTable = ""; ' threw exception 'Code has syntax errors:
Line 1, Col 9 '=': Failed to parse Letter of Name.
Line 1, Col 9 '=': Failed to parse Name of VarName.
Line 1, Col 9 '=': Failed to parse 'nil' of NilLiteral.
Line 1, Col 9 '=': Failed to parse Text of BoolLiteral.
Line 1, Col 9 '=': Failed to parse '0'...'9' of Digit.
Line 1, Col 9 '=': Failed to parse (Digit)+ of FloatNumber.
Line 1, Col 9 '=': Failed to parse Name of VariableArg.
Line 1, Col 9 '=': Failed to parse firstTerm of OperatorExpr.
Line 1, Col 9 '=': Failed to parse Expr of ExprStmt.
Line 1, Col 9 '=': Failed to parse remaining input.
'
UnityEngine.Debug:LogError (object)
PixelCrushers.DialogueSystem.Lua:RunRaw (string,bool,bool) (at Assets/Plugins/Pixel Crushers/Dialogue System/Scripts/Lua/Lua Wrapper/Lua Interpreter/Lua.cs:228)
PixelCrushers.DialogueSystem.Lua:Run (string,bool,bool) (at Assets/Plugins/Pixel Crushers/Dialogue System/Scripts/Lua/Lua Wrapper/Lua Interpreter/Lua.cs:129)
PixelCrushers.DialogueSystem.Lua:Run (string,bool) (at Assets/Plugins/Pixel Crushers/Dialogue System/Scripts/Lua/Lua Wrapper/Lua Interpreter/Lua.cs:139)
PixelCrushers.DialogueSystem.PersistentDataManager:ApplyLuaInternal (string,bool) (at Assets/Plugins/Pixel Crushers/Dialogue System/Scripts/Save System/PersistentDataManager.cs:261)
PixelCrushers.DialogueSystem.DialogueSystemSaver:ApplyDataImmediate () (at Assets/Plugins/Pixel Crushers/Dialogue System/Scripts/Save System/DialogueSystemSaver.cs:64)
PixelCrushers.SaveSystem:ApplyDataImmediate () (at Assets/Plugins/Pixel Crushers/Common/Scripts/Save System/SaveSystem.cs:779)
PixelCrushers.SaveSystem/<LoadSceneCoroutine>d__107:MoveNext () (at Assets/Plugins/Pixel Crushers/Common/Scripts/Save System/SaveSystem.cs:756)
UnityEngine.SetupCoroutine:InvokeMoveNext (System.Collections.IEnumerator,intptr) (at /Users/bokken/buildslave/unity/build/Runtime/Export/Scripting/Coroutines.cs:17)