aboutsummaryrefslogtreecommitdiff
path: root/cpp04/ex01/SuperMutant.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp04/ex01/SuperMutant.cpp')
-rw-r--r--cpp04/ex01/SuperMutant.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/cpp04/ex01/SuperMutant.cpp b/cpp04/ex01/SuperMutant.cpp
index ba0a8a9..c9ce83c 100644
--- a/cpp04/ex01/SuperMutant.cpp
+++ b/cpp04/ex01/SuperMutant.cpp
@@ -6,27 +6,26 @@
/* By: charles <charles.cabergs@gmail.com> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/04/14 13:30:47 by charles #+# #+# */
-/* Updated: 2020/04/14 13:34:32 by charles ### ########.fr */
+/* Updated: 2020/11/12 13:54:19 by cacharle ### ########.fr */
/* */
/* ************************************************************************** */
#include "SuperMutant.hpp"
-SuperMutant::SuperMutant()
- : Enemy(170, "Super Mutant")
+SuperMutant::SuperMutant() : Enemy(170, "Super Mutant")
{
std::cout << "Gaaah. Me want smash heads!" << std::endl;
}
-SuperMutant::SuperMutant(SuperMutant const& other)
+SuperMutant::SuperMutant(SuperMutant const& other) : Enemy(other)
{
std::cout << "Gaaah. Me want smash heads!" << std::endl;
- *this = other;
}
-void SuperMutant::operator=(SuperMutant const& other)
+SuperMutant& SuperMutant::operator=(SuperMutant const& other)
{
Enemy::operator=(other);
+ return *this;
}
SuperMutant::~SuperMutant()