Beispiel #1
0
 //Origin; transform of the NPC
 public void InitDialogue(Transform npcOrigin, string NPCId)
 {
     origin         = npcOrigin;
     npcDialogue    = ResourcesManager.Instance.GetNPCDialogue(NPCId);
     npcState       = SessionManager.Instance.GetNPCState(NPCId);
     dialogueActive = true;
     textObj.SetActive(true);
     updateDialogue = false;
     lineIndex      = 0;
 }
        public void PlayEvent(string eventID)
        {
            int index = -1;

            events_IDs.TryGetValue(eventID, out index);

            switch (index)
            {
            case -1:
                return;

            case 0:
                NPCStates npcState = GetNPCState("npc1");
                npcState.dialogueIndex = 3;
                break;

            default:
                break;
            }
        }