示例#1
0
        /// <summary>
        /// Creates a new <code>Player</code>.
        /// </summary>
        /// <param name="name">The <code>Player</code>'s name.</param>
        /// <param name="isMale">Is <code>Player</code> a male?</param>
        /// <param name="hitPoints">The <code>Player</code>'s hit points.</param>
        /// <param name="memoryPoints">The <code>Player</code>'s memory points.</param>
        /// <param name="weapons">The <code>Player</code>'s acquired weapons.</param>
        /// <param name="primaryWield">The <code>Player</code>'s <code>Weapon</code> for primary wield.</param>
        /// <param name="secondaryWield">The <code>Player</code>'s <code>Weapon</code> for secondary wield.</param>
        public Player(string name,
					  bool isMale,
					  byte hitPoints = 100,
					  byte memoryPoints = 0,
					  List<Weapon> weapons = null,
					  Weapon primaryWield = null,
					  Weapon secondaryWield = null)
            : base(name)
        {
            Name = name;
            IsMale = isMale;
            HitPoints = hitPoints;
            MemoryPoints = memoryPoints;
            Weapons = weapons;
            PrimaryWield = primaryWield;
            SecondaryWield = secondaryWield;
        }
示例#2
0
        /// <summary>
        /// Constructs a new <code>WeaponPowerup</code>.
        /// </summary>
        /// <param name="name">The <code>WeaponPowerup</code>'s name.</param>
        /// <param name="weapon">The <code>Weapon</code> that the <code>WeaponPowerup</code> corresponds to.</param>
        /// <param name="isPickableByNPC">Boolean value indicating if this <code>WeaponPowerup</code> can be picked by NPCs.</param>
        public WeaponPowerup(string name,
					  Weapon weapon,
					  bool isPickableByNPC = false)
            : base(name, isPickableByNPC)
        {
            Weapon = weapon;
        }