I'm struggling on an error related to SimStatus. I've tried everything, I can't find where the problem is
I'm using simstatus checks everywhere in the game, but in THIS specific case, it logs an error and the dialogue entry is skipped:
My dialogue setup looks like this:
Nothing special, only a simstatus check in the condition field of the 3rd response choice.
Lua throws an error when running this code:
Code: Select all
return Dialog[thisID].SimStatus ~= Variable["SimStatus.WasDisplayed"]
But as you can see in the error message, the problem is in fact that lua can't find the Dialog[thisID] element. The ID variable has been set to "12" previously, though, as you can in see in the logs.
During this conversation, if I run the code manually in the lua console:
Code: Select all
return Conversation[54].Dialog[12].SimStatus ~= "WasDisplayed"
Code: Select all
return Dialog[12].SimStatus ~= "WasDisplayed"
Can you see a situation where the "shortcut" dialog[id] could points to the wrong conversation ID? I've tried to find the piece of code handling this, but I can't find where it is :/
I hope you'll find what's wrong here (you always do, don't you?)
Marc