From: Dominik Kaiser Date: Mon, 10 Feb 2025 10:34:52 +0000 (+0100) Subject: Add zombieHorde func X-Git-Url: https://git.dkaiser.de/?a=commitdiff_plain;h=1d593b80d53124b96c2fcee1106b6fff88a2375b;p=42%2Fcpp01.git Add zombieHorde func --- diff --git a/ex01/Zombie.cpp b/ex01/Zombie.cpp index bbd0a65..92d3a5f 100644 --- a/ex01/Zombie.cpp +++ b/ex01/Zombie.cpp @@ -6,13 +6,16 @@ /* By: dkaiser +Zombie::Zombie(void) +{} + Zombie::Zombie(const std::string &name) :name(name) {} @@ -26,3 +29,8 @@ void Zombie::announce(void) { std::cout << name << ": BraiiiiiiinnnzzzZ..." << std::endl; } + +void Zombie::setName(const std::string &name) +{ + this->name = name; +} diff --git a/ex01/Zombie.hpp b/ex01/Zombie.hpp index 5c96e80..8f539d2 100644 --- a/ex01/Zombie.hpp +++ b/ex01/Zombie.hpp @@ -6,7 +6,7 @@ /* By: dkaiser