forked from github/server
38 lines
1.4 KiB
C
38 lines
1.4 KiB
C
/* vi: set ts=2:
|
|
*
|
|
*
|
|
* Eressea PB(E)M host Copyright (C) 1998-2003
|
|
* Christian Schlittchen (corwin@amber.kn-bremen.de)
|
|
* Katja Zedel (katze@felidae.kn-bremen.de)
|
|
* Henning Peters (faroul@beyond.kn-bremen.de)
|
|
* Enno Rehling (enno@eressea-pbem.de)
|
|
* Ingo Wilken (Ingo.Wilken@informatik.uni-oldenburg.de)
|
|
*
|
|
* This program may not be used, modified or distributed without
|
|
* prior permission by the authors of Eressea.
|
|
*/
|
|
|
|
#ifndef H_KRNL_PATHFINDER
|
|
#define H_KRNL_PATHFINDER
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#define MAXDEPTH 1024
|
|
|
|
extern int search[MAXDEPTH][2];
|
|
extern int search_len;
|
|
|
|
extern struct region ** path_find(struct region *start, const struct region *target, int maxlen, boolean (*allowed)(const struct region*, const struct region*));
|
|
extern boolean path_exists(struct region *start, const struct region *target, int maxlen, boolean (*allowed)(const struct region*, const struct region*));
|
|
extern boolean allowed_swim(const struct region * src, const struct region * target);
|
|
extern boolean allowed_fly(const struct region * src, const struct region * target);
|
|
extern boolean allowed_walk(const struct region * src, const struct region * target);
|
|
extern struct region_list * regions_in_range(struct region * src, int maxdist, boolean (*allowed)(const struct region*, const struct region*));
|
|
|
|
extern void pathfinder_cleanup(void);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
#endif
|