Yeah, this really isn't wanting to work. Gonna need to probably redo everything

This commit is contained in:
2015-08-22 10:44:05 -07:00
parent 47fee51b08
commit 17207d8294
9 changed files with 226 additions and 63 deletions

View File

@@ -8,7 +8,7 @@ class Pather;
class node {
public:
node(sf::Vector2i XY, int h, int cF, int cL, node* p, Pather* pather_);
node(sf::Vector2i XY, double h, int cF, int cL, node* p, Pather* pather_);
node();
~node();
@@ -16,7 +16,7 @@ public:
// Ugh, pointers, ugh c++
node* parent;
int hueristic;
double hueristic;
int cameFrom;
int closedList;
Pather* pather;
@@ -33,15 +33,17 @@ public:
Map* map;
std::unordered_map<node*, int> openList;
std::unordered_map<node*, int> closedList;
int visitedMap[App::WINDOW_HEIGHT][App::WINDOW_WIDTH];
std::unordered_map<node*, double> openList;
std::unordered_map<node*, double> closedList;
MultiArray<int, Map::CELLS_WIDTH , Map::CELLS_HEIGHT> visitedMap;
//int visitedMap[App::WINDOW_HEIGHT][App::WINDOW_WIDTH];
std::deque<int> pathTo(sf::Vector2i start, sf::Vector2i end);
std::deque<int> loop();
std::deque<int> returnPath();
std::deque<int> pathTo(sf::Vector2i start, sf::Vector2i end);
std::deque<int> loop();
std::deque<int> returnPath();
sf::Vector2i getEndNodePosition();
sf::Vector2i getEndNodePosition();
node* start_node;
node* active_node;