Code: Select all
public static double Test(double value) {
var state = DialogueManager.Instance.CurrentConversationState;
var id = ArticyBridge.GetArticyIdField(state.subtitle.dialogueEntry);
Debug.LogFormat("ModifyOnce: {0}", id);
return (double)value;
}
The function Test is put into the PC response instruction -- the dialogue written in Articy is like this:
NPC - hub - PC - PC
which probably converts into (?):
NPC - group - PC - PC
Now my Test function, when called from Lua gives the current entry as the NPC entry, while the actual clicked node from which it ran was the second PC line.
I am probably mistaken on the state.subtitle.dialogueEntry is the last NPC spoken line.
How could I find the actual entry from which I am calling the Lua function? The function should be able to run on both PC and NPC entries...