no error, nor warning
let me give me a few details and my debug data:
I have created a simple conversation as in the attachment screenshot
both in "How are you" and "ok" nodes, i added following script:
Code: Select all
if (Dialog[thisID].SimStatus =="Untouched") then Variable["test"] = Variable["test"] + 1 end;
the result is the variable "test" value doesn't get increased
however, if I take out the condidtion, just use
Code: Select all
Variable["test"] = Variable["test"] + 1
it works.
I also tried doing some debugs from unity script (I don't know how to add logging directly from the dialogue entry script field)
I added following line inside OnConversationLine() function
Code: Select all
Debug.Log(subtitle.dialogueEntry.outgoingLinks[0].destinationDialogueID + " : " + DialogueLua.GetSimStatus(subtitle.dialogueEntry.outgoingLinks[0].destinationConversationID, subtitle.dialogueEntry.outgoingLinks[0].destinationDialogueID));
reason I use destinationConversationID and destinationDialogueID is that in OnConversationLine() method, checking current dialogue entry simstatus always returns "WasDisplayed", guess the simstatus was updated before executing the OnConversationLine()
result of my debug is, both returns "WasOffered", even the entry hasn't played yet.
so I went back to the dialogue editor, replace the above script from condition "Untouched" to "WasOffered", still not working
lastly, if I replace the condition to "WasDisplayed", it's working, but obliviously, this is not what I want
am I missing anything? tks