From 0bc3cb460aa1857c081688d6186d71421c1ee640 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Sun, 31 Aug 2008 09:53:33 -0400 Subject: [PATCH] Simplify mapdist() It became needlessly complicated in 4.0.1 to fix a "bug in mapdist not taking world edges into account nicely enough." That "fix" had no effect, which was good, because it wasn't broken. --- src/lib/common/mapdist.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/lib/common/mapdist.c b/src/lib/common/mapdist.c index 50d90c00c..098789be4 100644 --- a/src/lib/common/mapdist.c +++ b/src/lib/common/mapdist.c @@ -70,10 +70,6 @@ mapdist(int x1, int y1, int x2, int y2) { int dx, dy; - x1 = x1 % WORLD_X; - y1 = y1 % WORLD_Y; - x2 = x2 % WORLD_X; - y2 = y2 % WORLD_Y; dx = deltax(x1, x2); dy = deltay(y1, y2); if (dx > dy) -- 2.43.0