|
@@ -1,16 +1,6 @@
|
|
|
#include "../include/Cell.h"
|
|
|
-#include <assert.h>
|
|
|
+#include "../include/units/unit.h"
|
|
|
#include <string>
|
|
|
-#include <string.h>
|
|
|
-/*
|
|
|
- * ????? ??????? ??? ???? ? ?????????? ?????????? ????
|
|
|
- */
|
|
|
-//#include "../include/units/unit.h"
|
|
|
-class Unit{
|
|
|
-public:
|
|
|
- bool canMoveForDistance(int){return false;}
|
|
|
- bool canAttackForDistance(std::string, int){return false;}
|
|
|
-};
|
|
|
#include <queue>
|
|
|
#include <vector>
|
|
|
#include <map>
|
|
@@ -158,7 +148,7 @@ std::vector <Cell*> Cell::actualPath(Cell* to) {
|
|
|
parent = TestParent;
|
|
|
}
|
|
|
};
|
|
|
- assert(parent != nullptr);
|
|
|
+ if(parent == nullptr)throw std::string("Don`t recalculated");
|
|
|
f(to->getleftUp(), to);
|
|
|
f(to->getleft(), to);
|
|
|
f(to->getleftDown(), to);
|