示例#1
0
        public Warrior(string name    = "Warrior",
                       int initiative = -1, int maxHealth = 200,
                       int maxMana    = 0, int attack     = 15, int defense = 10)
            : base(initiative, 50)
        {
            _name           = name;
            _maxHealthPoint = maxHealth;
            _healthPoint    = maxHealth;
            _maxManaPoint   = maxMana;
            _manaPoint      = maxMana;
            _attack         = attack;
            _defense        = defense;

            _weapon  = new Weapons.Sword("Sword", attack);
            _objects = new List <Objects.AObject>();
            _objects.Add(new Objects.Potion("HealPotion"));
            _objects.Add(new Objects.Potion("HealPotion"));
        }
示例#2
0
        public Wizard(string name    = "Wizard",
                      int initiative = -1, int maxHealth = 100,
                      int maxMana    = 50, int attack    = 8, int defense = 8)
            : base(initiative, 20)

        {
            _name           = name;
            _maxHealthPoint = maxHealth;
            _healthPoint    = maxHealth;
            _maxManaPoint   = maxMana;
            _manaPoint      = maxMana;
            _attack         = attack;
            _defense        = defense;

            _weapon = new Weapons.Sword("Old Sword", attack);
            _spells = new List <Spells.ASpell>();
            _spells.Add(new Spells.AttackSpell());
            _spells.Add(new Spells.HealSpell());
        }