-
Notifications
You must be signed in to change notification settings - Fork 8
/
PathFinder.cpp
57 lines (48 loc) · 1.04 KB
/
PathFinder.cpp
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
56
57
#include "PathFinder.hpp"
#include "AreaTransition.hpp"
Directions PathFinder::DeterminePathByMap(UINT16 Area)
{
if (Area == 0)
return NONE;
if (Area == 132)
{
//set destination area back to highgate to enter portal at end
printf("Detected blood aquaduct... Path: North west\n");
SetPathDirection(NORTH_WEST);
return NORTH_WEST;
}
else if (Area == 133)
{
if (GetDestinationArea() == 132)
{
SetPathDirection(WAYPOINT_INTERACTION);
printf("Path direction: Waypoint\n");
return WAYPOINT_INTERACTION;
}
}
return NONE;
}
VOID PathFinder::SetPathDirection(Directions d)
{
this->PathDirection = d;
}
VOID PathFinder::SetArea(UINT16 Area)
{
this->CurrentArea = Area;
}
VOID PathFinder::SetDestinationArea(UINT16 Area)
{
this->DestinationArea = Area;
}
UINT16 PathFinder::GetCurrentArea()
{
return this->CurrentArea;
}
UINT16 PathFinder::GetDestinationArea()
{
return this->DestinationArea;
}
Directions PathFinder::GetPathDirection()
{
return this->PathDirection;
}