-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsim.hpp
More file actions
55 lines (45 loc) · 888 Bytes
/
Copy pathsim.hpp
File metadata and controls
55 lines (45 loc) · 888 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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#ifndef SIM_HPP
#define SIM_HPP
#include "object.hpp"
#include "entity.hpp"
#include "map.hpp"
#ifndef max
#define max(a,b) (((a) (b)) ? (a) : (b))
#endif
#ifndef min
#define min(a,b) (((a) < (b)) ? (a) : (b))
#endif
class Sim
{
public:
Sim();
void tick();
Map* getMap();
bool populateMap();
bool spawn();
int entitiesAtGoal();
void overrideEntitiesAtGoal(int e);
int activeEntities();
int* getTowerList();
std::string getTowerListString();
void setTowersFromList(int* tlist, int num);
void mutateTower();
void crossoverTowers(Sim* s1, Sim* s2);
void setSpawnPerTick(int s);
int getSpawnPerTick();
void encodeForMPI(int* a);
~Sim();
protected:
Map* map;
int numTowers;
int numEntities;
int spawnPerTick;
int overrideEntities;
};
class BigSim: public Sim
{
public:
BigSim();
~BigSim();
};
#endif // SIM_HPP