using System.Collections; using System.Collections.Generic; using UnityEngine; using TMPro; public class OpenInventoryKeyChanger : MonoBehaviour { private TMP_Text thisText; private string textToShow; void Awake() { thisText = GetComponent(); } // Update is called once per frame void Update() { if (UIManager.Instance.Inventory.activeInHierarchy) { thisText.text = "[[Inventory]]"; } else { thisText.text = "[[Inventory]]"; } textToShow = thisText.text; thisText.text = InputMessageHandler.Instance.Interpolate($"{textToShow}"); } }