public void OnConfirm()
 {
     bPanel.battlePhase.battleData.attackerSideInfo.SetPostBattleArmyData_RemainingArmy(attackerPanel.BakeIntoArmy());
     bPanel.battlePhase.battleData.defenderSideInfo.SetPostBattleArmyData_RemainingArmy(defenderPanel.BakeIntoArmy());
     if (!bPanel.battlePhase.battleData.BattleEndCheck())
     {
         //we only need to update side info displays if the battle hasn't ended yet,
         //because the delegate would take care of it otherwise
         bPanel.UpdateArmyDisplays();
     }
 }
예제 #2
0
    public void OnConfirmPercentages()
    {
        bPanel.battlePhase.battleData.attackerSideInfo.SetPostBattleArmyData_RemainingPercent(attackerBox.sliderGroup.theSlider.value);
        bPanel.battlePhase.battleData.defenderSideInfo.SetPostBattleArmyData_RemainingPercent(defenderBox.sliderGroup.theSlider.value);

        if (!bPanel.battlePhase.battleData.BattleEndCheck())
        {
            //we only need to update side info displays if the battle hasn't ended yet,
            //because the delegate would take care of it otherwise
            bPanel.UpdateArmyDisplays();
        }
    }