-
Notifications
You must be signed in to change notification settings - Fork 1
/
hero.h
33 lines (28 loc) · 952 Bytes
/
hero.h
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
#ifndef HERO__
#define HERO__
#include "entity.h"
#include <string>
class Player;
class Ally : public Entity {
private:
std::string command;
bool hasCommand = false;
public:
bool goCoord(intPair coord);
bool goDefaultCoord(Player &player);
bool goEntity(int id, Player &player);
bool spellWind(int x, int y);
bool spellWind(intPair coord);
bool control(int id, int x, int y, Player &player);
bool shield(int id, Player &player);
std::string getCommand() const;
Ally(){};
Ally(int id, int type, int x, int y, int shieldLife, int isControlled, int health, int vx, int vy, int nearBase, int threatFor, intPair baseCoord);
};
class Enemy : public Entity {
public:
Enemy(){};
Enemy(int id, int type, int x, int y, int shieldLife, int isControlled, int health, int vx, int vy, int nearBase, int threatFor, intPair baseCoord);
};
std::ostream& operator << (std::ostream & os,const Ally & a);
#endif