Example #1
0
        // Player Announcements ---------
        public static void PlayerAttack(int Weapon, int Damage, int StaminaPenalty, int DragonDefence)
        {
            string WeaponName;

            if (Weapon == 1)
            {
                WeaponName = "Longsword";
            }
            else if (Weapon == 2)
            {
                WeaponName = "Battle-Axe";
            }
            else if (Weapon == 3)
            {
                WeaponName = "Spears";
            }
            else
            {
                throw new Exception("\n\n--Error!\nPlayer attack weapon has invalid value!");
            }

            int TotalDamage = Damage - DragonDefence;

            File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} attacks with " +
                               $"{WeaponName} ({Damage}dmg), causing {TotalDamage}dmg total ({DragonDefence} Dragon Defence), " +
                               $"for {StaminaPenalty} Stamina.");
        }
Example #2
0
        // Dragon Announcements ---------
        public static void DragonAttack(int Stance, int Damage, int StaminaPenalty, int Fury, int PlayerDefence)
        {
            string StanceName;

            if (Stance == 1)
            {
                StanceName = "Claws";
            }
            else if (Stance == 2)
            {
                StanceName = "Spear";
            }
            else if (Stance == 3)
            {
                StanceName = "Fire";
            }
            else
            {
                throw new Exception("\n\n--Error!\nStance in dragon attack has invalid value!");
            }

            int TotalDamage = Damage + Fury - PlayerDefence;

            File.AppendAllText(LogPath, $"\nDragon attacks with {StanceName} (" +
                               $"{Damage}dmg + {Fury}dmg of Fury), causing {TotalDamage}dmg total ({PlayerDefence} " +
                               $"{ChampMenu.GetChampName()} defence), for {StaminaPenalty} Stamina.");
        }
Example #3
0
        public BattleSource(int ChampChoiceInput)
        {
            ChampChoice = ChampChoiceInput;
            champName   = ChampMenu.GetChampName();

            Start();
        }
Example #4
0
 public static void PlayerRest(int Turns, int RestHP, int RestStamina)
 {
     if (Turns > 1)
     {
         File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} rests for {Turns} turns, " +
                            $"for each turn gains {RestHP}hp and {RestStamina} Stamina.");
     }
     else
     {
         File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} rests for {Turns} turn, " +
                            $"for each turn gains {RestHP}hp and {RestStamina} Stamina.");
     }
 }
Example #5
0
        public static void PlayerNewWeapon(int newWeapon)
        {
            string newWeaponName;

            if (newWeapon == 1)
            {
                newWeaponName = "Longsword";
            }
            else if (newWeapon == 2)
            {
                newWeaponName = "Battle-Axe";
            }
            else if (newWeapon == 3)
            {
                newWeaponName = "Spears";
            }
            else
            {
                throw new Exception("\n\n--Error!\nShow weapon in interface has invalid value!");
            }

            File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} switches weapons to {newWeaponName}.");
        }
Example #6
0
        public static void PlayerNewLocation(int newLocation)
        {
            string newLocationName;

            if (newLocation == 1)
            {
                newLocationName = "Rocks";
            }
            else if (newLocation == 2)
            {
                newLocationName = "Huts";
            }
            else if (newLocation == 3)
            {
                newLocationName = "Trees";
            }
            else
            {
                throw new Exception("\n\n--Error!\nPlayer location switch has invalid value!");
            }

            File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} switches location to the " +
                               $"{newLocationName}.");
        }
Example #7
0
 public static void PlayerDiffLocation()
 {
     File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} can't melee attack! The dragon " +
                        $"is in a different location!");
 }
Example #8
0
 public static void PlayerNoStamina()
 {
     File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} doesn't have enough energy " +
                        $"to finish the attack!");
 }
Example #9
0
 public static void PlayerPotion(int PotionHealth)
 {
     File.AppendAllText(LogPath, $"\n{ChampMenu.GetChampName()} drinks a potion, " +
                        $"gains {PotionHealth} health.");
 }