diff options
Diffstat (limited to 'cpp01/ex06/HumanA.cpp')
| -rw-r--r-- | cpp01/ex06/HumanA.cpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/cpp01/ex06/HumanA.cpp b/cpp01/ex06/HumanA.cpp new file mode 100644 index 0000000..8d9b449 --- /dev/null +++ b/cpp01/ex06/HumanA.cpp @@ -0,0 +1,24 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* HumanA.cpp :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/02/02 16:44:03 by cacharle #+# #+# */ +/* Updated: 2020/02/02 16:54:07 by cacharle ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#include "HumanA.hpp" + +HumanA::HumanA(std::string name, Weapon weapon) +{ + this->name = name; + this->weapon = weapon; +} + +void HumanA::attack() +{ + std::cout << name << " attack with his " << weapon.getType(); +} |
