int main(void) { Zombie * marvin; Zombie * random; std::cout << "<Main> Creation of a zombie by default" << std::endl; Zombie livingDead; livingDead.announce(); std::cout << std::endl; ZombieEvent event; std::cout << std::endl << "<Main> Adding a type to the existing zombie" << std::endl; event.setZombieType("Hungry"); std::cout << "<Main> Checking the zombie type in the main : [" << event.getZombieType() << "]" << std::endl; std::cout << std::endl << "<Main> Creation of a zombie called Marvin" << std::endl; marvin = event.newZombie("Marvin"); std::cout << "<Main> What is it zombie?" << std::endl; marvin->announce(); std::cout << "<Main> Get away Marvin!" << std::endl; delete marvin; std::cout << std::endl << "<Main> Creation of a random zombie with type Hungry" << std::endl; random = event.randomChump(); std::cout << "<Main> I will destroy you now" << std::endl; delete random; std::cout << "<Main> This is the end, computer always win." << std::endl; return (0); }
int main(void) { ZombieEvent event; srand(time(NULL)); std::cout << "OMG! FUS ZOMBIES COMMING" << std::endl; wave(event, "FUS", 5); std::cout << "OMG! RO ZOMBIES COMMING" << std::endl; wave(event, "RO", 5); std::cout << "OMG! DA ZOMBIES COMMING" << std::endl; wave(event, "DA", 5); std::cout << "LOL F****D UP ZOMBIE" << std::endl; event.randomChump(); event.randomChump(); event.randomChump(); event.randomChump(); event.randomChump(); event.randomChump(); return (0); }
int main(void) { ZombieEvent event = ZombieEvent(); Zombie* michael = event.newZombie("michael"); michael->Announce(); delete michael; event.randomChump(); Zombie julie = Zombie("julie", "runner"); julie.Announce(); return (0); }
int main(void) { srand(time(0)); ZombieEvent eve = ZombieEvent(); Zombie *z1 = eve.randomChump(); eve.setZombieType("SWAAAAAG"); Zombie *z2 = eve.randomChump(); Zombie *z3 = eve.randomChump(); eve.setZombieType("Bobo Parisien"); Zombie *z4 = eve.randomChump(); z1->announce(); z2->announce(); z4->announce(); z3->announce(); delete z1; delete z2; delete z3; delete z4; return (0); }