diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-04-13 10:33:05 +0200 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-04-13 10:33:05 +0200 |
| commit | 0f3240844dbd5a874e1565a988ef355ededab6a5 (patch) | |
| tree | efc1a1307863d173be17a12fbab6b84fe7d00960 /cpp01/ex02/Zombie.cpp | |
| parent | 629d52b1262879a346e9ca17567a8f483c60ba0a (diff) | |
| download | piscine_cpp-0f3240844dbd5a874e1565a988ef355ededab6a5.tar.gz piscine_cpp-0f3240844dbd5a874e1565a988ef355ededab6a5.tar.bz2 piscine_cpp-0f3240844dbd5a874e1565a988ef355ededab6a5.zip | |
Fixing cpp01
Diffstat (limited to 'cpp01/ex02/Zombie.cpp')
| -rw-r--r-- | cpp01/ex02/Zombie.cpp | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/cpp01/ex02/Zombie.cpp b/cpp01/ex02/Zombie.cpp index 2ea23b6..40fb849 100644 --- a/cpp01/ex02/Zombie.cpp +++ b/cpp01/ex02/Zombie.cpp @@ -1,14 +1,25 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* Zombie.cpp :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: charles <charles.cabergs@gmail.com> +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/04/13 09:38:16 by charles #+# #+# */ +/* Updated: 2020/04/13 09:40:20 by charles ### ########.fr */ +/* */ +/* ************************************************************************** */ + #include <iostream> #include "Zombie.hpp" -Zombie::Zombie(std::string n, std::string t) +Zombie::Zombie(std::string name, std::string type) + : m_name(name), m_type(type) { - name = n; - type = t; announce(); } void Zombie::announce() { - std::cout << "<" << name << " (" << type << ")> Braiiiiiiinnnssss..." << std::endl; + std::cout << "<" << m_name << " (" << m_type << ")> Braiiiiiiinnnssss..." << std::endl; } |
