aboutsummaryrefslogtreecommitdiff
path: root/cpp03/ex04/ClapTrap.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp03/ex04/ClapTrap.hpp')
-rw-r--r--cpp03/ex04/ClapTrap.hpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/cpp03/ex04/ClapTrap.hpp b/cpp03/ex04/ClapTrap.hpp
index 5f4e26a..8d38307 100644
--- a/cpp03/ex04/ClapTrap.hpp
+++ b/cpp03/ex04/ClapTrap.hpp
@@ -6,7 +6,7 @@
/* By: charles <charles.cabergs@gmail.com> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/04/13 15:20:45 by charles #+# #+# */
-/* Updated: 2020/04/13 15:47:14 by charles ### ########.fr */
+/* Updated: 2020/11/11 07:29:18 by cacharle ### ########.fr */
/* */
/* ************************************************************************** */
@@ -21,9 +21,9 @@ class ClapTrap
{
public:
ClapTrap();
- ClapTrap(std::string name);
+ ClapTrap(std::string const& name);
ClapTrap(ClapTrap const& other);
- void operator=(ClapTrap const& other);
+ ClapTrap& operator=(ClapTrap const& other);
~ClapTrap();
void rangedAttack(std::string const& target) const;
@@ -32,14 +32,12 @@ public:
void beRepaired(unsigned int amount);
protected:
- std::string m_prefix;
-
unsigned int m_hitPoints;
unsigned int m_maxHitPoints;
unsigned int m_energyPoints;
unsigned int m_maxEnergyPoints;
unsigned int m_level;
- std::string m_name;
+ std::string m_name;
unsigned int m_meleeAttackDamage;
unsigned int m_rangedAttackDamage;
unsigned int m_armorDamageReduction;