-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAgent.h
49 lines (34 loc) · 864 Bytes
/
Agent.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#ifndef AGENTPROJECT_AGENT_H
#define AGENTPROJECT_AGENT_H
#include <queue>
#include "Map.h"
#include "Effector.h"
#include "Sensor.h"
#include "Graph.h"
// Variable définissant le w de la pénalité pour un bijou aspiré
#define JEWEL_PENALTY 1
// Variables pour les tests
#define MAX_LEARNING_RATE 6
#define TEST_DURATION 10s
#define TEST_NUMBER 5
class Agent {
public:
explicit Agent(Map *mp, bool smart = false);
~Agent();
void agentWork(int, int);
std::vector<Graph::node> getActions(int);
Sensor * sens;
Effector * eff;
bool smartAgent;
std::vector<Graph::node> actionList; // Intentions
int jewelCleaned = 0;
int batteryUsed = 0;
float perfEval() const;
float evaluatePerf(std::vector<float>);
void perform(int, const int, int);
int runTest();
private:
Map * map;
Graph * problem;
};
#endif //AGENTPROJECT_AGENT_H