using UnityEngine; // this class is specifically referring to items in the world that can be picked up public class PickupableItem : Interactable { public Item item; public override void Interact() { Debug.Log("Picked up " + item.itemName + "!"); MoveOutsideRange(); // I don't love this but if we destroy the object we probably need to do this first Destroy(gameObject); } public override void MoveInsideRange() { GameManager.Instance.DialogueManager.ShowItemText(item.itemName); } public override void MoveOutsideRange() { GameManager.Instance.DialogueManager.HideItemText(); } }