debut d01 ex03
This commit is contained in:
15
d01/ex03/HumanA.cpp
Normal file
15
d01/ex03/HumanA.cpp
Normal file
@@ -0,0 +1,15 @@
|
||||
#include "HumanA.hpp"
|
||||
|
||||
HumanA::HumanA( std::string name, Weapon weapon ) {
|
||||
|
||||
this->_name = name;
|
||||
this->_weapon = &weapon ;
|
||||
|
||||
}
|
||||
HumanA::~HumanA() {}
|
||||
|
||||
void HumanA::attack( void ) {
|
||||
|
||||
std::cout << this->_name << " attacks with their " << this->_weapon->getType() << std::endl;
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user