IEnumerator DelayUse() { CameraControls.Instance.SetParamaters(CameraControls.CameraSetup.CANNON); CameraControls.Instance.MatchTransform(playerPosition, adjustX, true); yield return(null); Debug.Log("Use"); Using = true; InteractionInfo[] info = new InteractionInfo[] { }; interaction.SetInteractions(info); InteractionManager.Instance.ClearInteraction(); stored = Inventory.Instance.GetStoredFromItem(itemNeeded); if (!Loaded) { if (stored != null) { if (stored.amount > 0) { InteractionManager.Instance.ShowBottomText(true); InteractionManager.Instance.SetBottomText(loadInteraction.GetInteractionMsg()); } } } else { if (stored != null) { if (stored.amount < itemNeeded.inventoryMax) { InteractionManager.Instance.ShowBottomText(true); InteractionManager.Instance.SetBottomText(unloadInteraction.GetInteractionMsg()); } } } }
public void Clear() { stored = null; slotUI.SetActive(false); }
public void Populate(StoredItem item) { slotUI.SetActive(true); stored = item; UpdateUI(); }