extern waypoint waypts[1000];

extern int chain[100];
extern int route;
extern int useWayPts;
extern int drawWayPts;
extern int numWayPts;

int findWay(int startP, int endP);
int initWaypoints(char *name);
int findBotPath(int a, int b, int *point, int *flags);
int findNearestPt(int x, int y);
int findSafePt(worm *tmpWorm, int x, int y);

#define AI_FLAG_JUMP 1
#define AI_FLAG_ROPE 2
#define AI_WYPT_SAFE 1

class aNode
{
public:
   aNode *previous;
   int waypoint;
   int costG, costH;
   int depth;
   int linkNum;
};

