public void BeginDialogue(Sprite portrait, string name, DialogueGraph graph) { currentGraph = graph; dialogueUI.SetActive(true); dialoguePortrait.sprite = portrait; dialogueName.text = name; StartCoroutine(ShowDialogue(0)); }
private DialogueGraphTransition[] GetTransitionsFor(DialogueGraph graph, int node) { LinkedList <DialogueGraphTransition> transitionsList = new LinkedList <DialogueGraphTransition>(); foreach (DialogueGraphTransition t in graph.transitions) { if (t.from == node) { transitionsList.AddLast(t); } } DialogueGraphTransition[] transitions = new DialogueGraphTransition[transitionsList.Count]; transitionsList.CopyTo(transitions, 0); return(transitions); }
public void changegra(Dialogue.DialogueGraph grap) { xdia = grap; }
void OnEnable() { graph = serializedObject.targetObject as DialogueGraph; nodes = serializedObject.FindProperty("nodes"); transitions = serializedObject.FindProperty("transitions"); }
public void SelectDialog(int index) { dialog = dialogList[index]; dialog.Restart(); }
public Conversation(DialogueGraph dialogue) { this.dialogue = dialogue; }