(WORLD_SZ): New.

(isok, ef_init, bmaps_intersect, bp_init, player_accept)
(finish_sects, main): Use it.

(bp_neighbors, bp_lbcost, pathcost): Use XYOFFSET().  No
functional change.
This commit is contained in:
Markus Armbruster 2007-07-28 12:12:17 +00:00
parent e24b608dc6
commit 56de7a2151
8 changed files with 18 additions and 16 deletions

View file

@ -36,7 +36,10 @@
#include "types.h"
/* Fast version of sctoff() for normalized arguments: */
/* Return the number of sectors in the world */
#define WORLD_SZ() (WORLD_X * WORLD_Y / 2)
/* Fast version of sctoff() for normalized arguments */
#define XYOFFSET(x, y) (((y) * WORLD_X + (x)) / 2)
#define XNORM(x) \