Tobis Programm forked to not destroy your golden files
Fork of Robocode by
Diff: source/Pathfinding.cpp
- Revision:
- 41:462d379e85c4
- Parent:
- 34:40d8d29b44b8
- Child:
- 44:7118b23b0fd7
- Child:
- 47:728502df3cb6
--- a/source/Pathfinding.cpp Tue Apr 04 15:37:40 2017 +0000 +++ b/source/Pathfinding.cpp Mon Apr 10 14:52:23 2017 +0000 @@ -28,11 +28,10 @@ using namespace std; -//will be replaced with +//global uint8_t obstacle_list[row][col] = { 0 }; - -//global position walkpath[5 * row] = { 0 }; +position target = {0}; //should be local static uint16_t open_list[row][col] = { 0 }; // contains open slots marked with their F value (G + H) @@ -52,7 +51,7 @@ { define_obst(); position start = { 1,1 }; //start - position target = { 198,198 }; //target + target.x = 198; target.y = 198; position current = { 0 }; //current pos memset(open_list, 0, sizeof(open_list));