Example #1
0
 public void OnDead()
 {
     ToolPotion.PotionType temp = DiffultyAdjuster.EvaluatePotionType();
     foreach (ToolPotion potion in tools)
     {
         if (potion.type.Equals(temp))
         {
             GameObject.Instantiate(potion.gameObject, transform.position, potion.gameObject.transform.rotation);
             break;
         }
     }
     Destroy(this.gameObject);
 }
Example #2
0
    // Update is called once per frame
    void Update()
    {
        if (Input.GetKeyDown(KeyCode.R))
        {
            //mapGenerator.tilemap.RefreshAllTiles();
            //Debug.Log("r");
            DiffultyAdjuster.EvaluatePotionType();
        }
        uiManager.UpdateCharacterUI();
        uiManager.UpdateTextWithGivenString(bossDebuffTipsUI, EventDispatcher.bossDebuffTips);
        if (Input.GetKeyDown(KeyCode.Escape))
        {
            ActivateRestartMenu();
        }

        if (Input.GetKeyDown(KeyCode.X))
        {
            DestroyAllEnmeies();
        }
    }