I have done a lot of research on the A * pathfinding algorithm and I am trying to integrate it into my program. This is not a game that I have created so I have no control over the frames. However, I am reading the necessary information from memory and I think I can create waypoints based on coordinates based on the physics of the game. Currently, I grab all the platforms that are within walking distance and stores them in their own doubly linked node according to their connection with their vertices. However, I don't know where to go from here. What other information should I store inside these nodes and how should I be connected from one list of nodes to another?

```
struct Platforms{
LONG x1;
LONG y1;
LONG x2;
LONG y2;
struct Platforms *prev;
struct Platforms *next;
};
std::vectorP;
void GetPlatforms(){
int platformCount = (int)ReadPointer(CWvsPhysicalSpace2DBase,OFS_PlatformCount);
LONG rightWall = ReadPointerSigned(CWvsPhysicalSpace2DBase, OFS_RightWall);
LONG leftWall = ReadPointerSigned(CWvsPhysicalSpace2DBase, OFS_LeftWall);
LONG downWall = ReadPointerSigned(CWvsPhysicalSpace2DBase, OFS_DownWall);
LONG upWall = ReadPointerSigned(CWvsPhysicalSpace2DBase, OFS_UpWall);
//add_log("Platform Count: %d", platformCount);
for(int i=0; i 0){ //Make sure the platform is traversable
//add_log("nnPlatform: %d X1: %d Y1: %d X2: %d Y2: %d", i+1, x1, y1, x2, y2);
if(P.size() > 0){
bool newHead = true;
for(std::vector::size_type i = 0; i != P.size(); i++) {
Platforms *curr = P(i);
while(curr != NULL){
if(curr->x1 == x2 && curr->y1 == y2){//curr->y1 - y2 > -50 && curr->y1 - y2 < 50){ //To account for slope
insert_front(&curr, x1, x2, y1, y2);
newHead = false;
//add_log("front segment found: X1: %d Y1: %d X2: %d Y2: %d", curr->x1, curr->y1, curr->x2, curr->y2);
break;
} else if(curr->x2 == x1 && curr->y2 == y1){
insert_After(curr, x1, x2, y1, y2);
newHead = false;
//add_log("connected segment found: X1: %d Y1: %d X2: %d Y2: %d", curr->x1, curr->y1, curr->x2, curr->y2);
break;
}
curr = curr->next;
}
}
if(newHead == true){
struct Platforms* head = NULL;
insert_end(&head, x1, x2, y1, y2);
P.push_back(head);
}
}else{
struct Platforms* head = NULL;
insert_end(&head, x1, x2, y1, y2);
P.push_back(head);
}
}
}
}
```