Ejemplo n.º 1
0
 public void SetSlider(CharacterController player, CharacterController enemy)
 {
     playerHpSlider.maxValue = player.RemainHP();
     playerApSlider.maxValue = player.RemainAP();
     enemyHpSlider.maxValue  = enemy.RemainHP();
     enemyApSlider.maxValue  = enemy.RemainAP();
 }
Ejemplo n.º 2
0
 public void UpdateTargetHpSlider(CharacterController player)
 {
     if (isEnemyMax == true)
     {
         enemyHpSlider.value = player.RemainHP();
         secondPlayerHP.text = "(" + enemyHpSlider.value.ToString() + "/" + enemyHpSlider.maxValue.ToString() + ")";
     }
 }
Ejemplo n.º 3
0
 public void UpdatePlayerHpSlider(CharacterController player)
 {
     if (isPlayerMax == true)
     {
         playerHpSlider.value = player.RemainHP();
         firstPlayerHP.text   = "(" + playerHpSlider.value.ToString() + "/" + playerHpSlider.maxValue.ToString() + ")";
     }
 }
Ejemplo n.º 4
0
            public void SetResultPlayerCheck(CharacterController myCharacter, CharacterController targetCharacter) //플레이어
            {
                InGameUIController ctn = Get <InGameUIController>((int)UI.ID.IngameUIController);

                if (targetCharacter.RemainHP() == 0)
                {
                    ctn.SetWinResultUI();
                    Debug.Log("SetResultPlayerCheck");
                    //결과창 UI를 띄우주기 위해 인게임 UI 컨트롤러 스크립트에 접속한다. (패배 결과창)
                }
                else if (myCharacter.RemainHP() == 0)
                {
                    ctn.SetDefeatResultUI();
                }

                //else
                //{
                //    ctn.SetFirstResultUI(1);
                //    //결과창 UI를 띄우주기 위해 인게임 UI 컨트롤러 스크립트에 접속한다. (승리 결과창)
                //}
            }