Exemple #1
0
        public void AttackCurrentMonster() // This is an On Click Event in xaml.cs
        {
            if (CurrentWeapon == null)
            {
                NullWeaponSelectionNotification();
            }

            if (BattleEngine.PlayerAccuracyCalculation())
            {
                BattleEngine.PlayerAttackDamageCalculation();
            }
            else
            {
                PlayerAttackFailureNotification();
                if (BattleEngine.MonsterAccuracyCalculation())
                {
                    BattleEngine.MonsterAttackDamageCalculation();
                }
                else
                {
                    MonsterAttackFailureNotification();
                }
            }
        }