using EasyTalk.Controller; using UnityEngine; public class NPC : Character { public enum NPCType { Villager, Merchant, Guard } public NPCType npcType; public float speed = 5f; public string npcName = "NPC"; // Start is called once before the first execution of Update after the MonoBehaviour is created void Start() { } // Update is called once per frame void Update() { } public void Interact() { if (npcType == NPCType.Merchant) { Debug.Log($"Welcome to my shop, {npcName}!"); } else if (npcType == NPCType.Villager) { //Debug.Log($"Hello there! I'm {npcName}, a humble villager."); dialogueController.ChangeDialogue(dialogue); dialogueController.PlayDialogue(); } else if (npcType == NPCType.Guard) { Debug.Log($"Stay out of trouble, citizen. I'm {npcName}, a guard."); } else { Debug.Log($"Greetings from {npcName}!"); } } }