]> git.pond.sub.org Git - empserver/blobdiff - src/lib/update/nxtsctp.c
Update copyright notice.
[empserver] / src / lib / update / nxtsctp.c
index fb9e7e92322cf2ac523edfef8746aca8d9fc6676..c2f1bd9a1680186537e2c1807da44e853ebd5e6a 100644 (file)
@@ -1,6 +1,6 @@
 /*
  *  Empire - A multi-player, client/server Internet based war game.
- *  Copyright (C) 1986-2000, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ *  Copyright (C) 1986-2004, Dave Pare, Jeff Bailey, Thomas Ruschak,
  *                           Ken Stevens, Steve McClure
  *
  *  This program is free software; you can redistribute it and/or modify
 struct sctstr *
 nxtsctp(register struct nstr_sect *np)
 {
-        while (1) {
-                np->dx++;
-                np->x++;
-                if (np->x >= WORLD_X)
-                        np->x = 0;
-                if (np->dx >= np->range.width) {
-                        np->dx = 0;
-                        np->x = np->range.lx;
-                        np->dy++;
-                        if (np->dy >= np->range.height)
-                                return (struct sctstr *)0;
-                        np->y++;
-                        if (np->y >= WORLD_Y)
-                                np->y = 0;
-                }
-                if ((np->y + np->x) & 01)
-                        continue;
-                if (np->type == NS_DIST) {
-                        np->curdist = mapdist(np->x, np->y, np->cx, np->cy);
-                        if (np->curdist > np->dist)
-                                continue;
-                }
-                return(getsectp(np->x, np->y));
-        }
-        /*NOTREACHED*/
+    while (1) {
+       np->dx++;
+       np->x++;
+       if (np->x >= WORLD_X)
+           np->x = 0;
+       if (np->dx >= np->range.width) {
+           np->dx = 0;
+           np->x = np->range.lx;
+           np->dy++;
+           if (np->dy >= np->range.height)
+               return (struct sctstr *)0;
+           np->y++;
+           if (np->y >= WORLD_Y)
+               np->y = 0;
+       }
+       if ((np->y + np->x) & 01)
+           continue;
+       if (np->type == NS_DIST) {
+           np->curdist = mapdist(np->x, np->y, np->cx, np->cy);
+           if (np->curdist > np->dist)
+               continue;
+       }
+       return (getsectp(np->x, np->y));
+    }
+    /*NOTREACHED*/
 }