#include "HumanA.hpp" #include #include HumanA::HumanA(const std::string& name, const Weapon& weapon) { this->_name = name; this->_weapon = weapon; } HumanA::HumanA() { std::cout << "HumanA()" << std::endl; } HumanA::HumanA(const HumanA& src) { *this = src; } HumanA::~HumanA() { std::cout << "~HumanA()" << std::endl; } HumanA& HumanA::operator=(const HumanA& src) { this->_weapon = src._weapon; this->_name = src._name; return *this; } void HumanA::attack() { std::cout << this->_name << " attacks with their " << this->_weapon.getType() << std::endl; }