-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMonster.h
More file actions
34 lines (22 loc) · 800 Bytes
/
Monster.h
File metadata and controls
34 lines (22 loc) · 800 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
//
// Created by Nativ on 18/01/2025.
//
#ifndef MONSTER_H
#define MONSTER_H
#include "Entity.h"
class Monster : public Entity {
public:
//constructors
Monster() : Entity() {};
Monster(const string &name, int maxAmountOfLife, int attackValue) : Entity(name, maxAmountOfLife, attackValue) {};
//destructor
virtual ~Monster();
virtual Monster* clone() const = 0;
//copy constructor and assignment operator
Monster(const Monster &monster) : Entity(monster) {};
Monster& operator=(const Monster &monster);
Monster& MonsterAttackedBySorcerer(const Player& player);
Monster& MonsterAttackedByFighter(const Player& player);
friend ostream& operator<<(ostream& os, const Monster& other);
};
#endif //MONSTER_H