d03 ex03 introduction template pour main
This commit is contained in:
30
d03/ex03/ScavTrap.cpp
Normal file
30
d03/ex03/ScavTrap.cpp
Normal file
@@ -0,0 +1,30 @@
|
||||
#include "ScavTrap.hpp"
|
||||
|
||||
ScavTrap::ScavTrap( std::string name ) : ClapTrap(name) {
|
||||
|
||||
_class = "ScavTrap";
|
||||
_hit = 100;
|
||||
_energy = 50;
|
||||
_attack = 20;
|
||||
|
||||
std::cout << _class << " " << ScavTrap::_name << " created with number " << _number << "\n";
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
* destructor
|
||||
*/
|
||||
|
||||
ScavTrap::~ScavTrap( void ) {
|
||||
std::cout << _class << " " << ScavTrap::_name << " destructed\n";
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
* special capacity
|
||||
*/
|
||||
|
||||
void ScavTrap::guardGate() {
|
||||
std::cout << _class << " " << ScavTrap::_name << " entered special mode Gate Keeper\n";
|
||||
}
|
||||
Reference in New Issue
Block a user