2 //! @brief Implementation of armor equipment
4 //! This class represents armor that is equipped or carried by a character
5 //! This class validates armor and assigns its stats
8 //! Default armor constructor sets stats to 1
16 //! Armor constructor sets stats.
17 //! @param armorClass: the armor class to be set
18 //! @param a_level the level to be set to
19 Armor::Armor(int armorClass
, int a_level
)
26 //! Armor constructor sets stats based on level.
27 //! @param a_level the level which designates stat values
28 Armor::Armor(int a_level
)
41 //! Validates the armor
42 //! Armor has an armor class attribute that must be between 1 and 5
43 bool Armor::validateEquipment()
45 if (ac
< 1 || ac
> 5 )
51 //! Sets the armor stats to the given level
52 void Armor::levelUpEquipment(int a_level
)