From b8e39b947890e74d82530e25ad9d02668aae1f0c Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Thu, 12 Nov 2020 15:46:07 +0100 Subject: Reformating cpp04 classes --- cpp04/ex01/AWeapon.hpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'cpp04/ex01/AWeapon.hpp') diff --git a/cpp04/ex01/AWeapon.hpp b/cpp04/ex01/AWeapon.hpp index 468f966..0296cd5 100644 --- a/cpp04/ex01/AWeapon.hpp +++ b/cpp04/ex01/AWeapon.hpp @@ -6,7 +6,7 @@ /* By: charles +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/04/14 11:22:06 by charles #+# #+# */ -/* Updated: 2020/04/14 14:33:07 by charles ### ########.fr */ +/* Updated: 2020/11/12 13:34:13 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -19,7 +19,7 @@ class AWeapon { public: AWeapon(AWeapon const& other); - void operator=(AWeapon const& other); + AWeapon& operator=(AWeapon const& other); virtual ~AWeapon(); AWeapon(std::string const& name, int apcost, int damage); @@ -29,10 +29,13 @@ public: virtual void attack() const = 0; protected: - AWeapon(); std::string m_name; - int m_apcost; - int m_damage; + int m_apcost; + int m_damage; + +private: + AWeapon(); + }; #endif -- cgit