Ejemplo n.º 1
0
    public void HideItemPickUpTheatric(Script_ItemPickUpTheatric theatric)
    {
        Debug.Log("***Calling HideItemPickUpTheatric now***");

        ItemPickUpTheatricsCanvasGroup.alpha = 0f;
        ItemPickUpTheatricsCanvasGroup.gameObject.SetActive(false);

        theatric.gameObject.SetActive(false);

        Script_Game.Game.ChangeStateLastState(null);
        /// Return the player back to Picking Up State and then immediately force done
        Script_Player p = Script_Game.Game.GetPlayer();

        p.SetIsPickingUp(p.GetItemShown());
        p.HandleEndItemDescriptionDialogue();
        p.SetItemShown(null);
    }
Ejemplo n.º 2
0
    public void ShowItemPickUpTheatric(Script_ItemPickUpTheatric theatric)
    {
        ItemPickUpTheatricsCanvasGroup.alpha = 1f;
        ItemPickUpTheatricsCanvasGroup.gameObject.SetActive(true);

        theatric.gameObject.SetActive(true);

        /// Must do this at end of frame or the "space" press will cause the item to be hidden
        StartCoroutine(WaitToChangeToCutScene());
        IEnumerator WaitToChangeToCutScene()
        {
            yield return(new WaitForEndOfFrame());

            Script_Game.Game.ChangeStateCutScene();
            /// Need to disable player's ability to move forward into item dialogue
            Script_Game.Game.GetPlayer().SetIsStandby();
        }
    }