summaryrefslogtreecommitdiff
path: root/landscape.c
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-02-01 06:32:03 +0000
committertron <tron@openttd.org>2006-02-01 06:32:03 +0000
commit9712d6f639c2a32aac05c22ff17cdb3ee32a977d (patch)
tree567a406e1224ab13f36027469339c6c42ada96f1 /landscape.c
parentf2c5567ab52345ef3830cea712d4ee7112ce8d7f (diff)
downloadopenttd-9712d6f639c2a32aac05c22ff17cdb3ee32a977d.tar.xz
(svn r3510) Fiddle with whitespace and parentheses
Diffstat (limited to 'landscape.c')
-rw-r--r--landscape.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/landscape.c b/landscape.c
index 839b5dbd4..689be3dab 100644
--- a/landscape.c
+++ b/landscape.c
@@ -175,7 +175,7 @@ uint GetPartialZ(int x, int y, int corners)
return z;
}
-uint GetSlopeZ(int x, int y)
+uint GetSlopeZ(int x, int y)
{
TileInfo ti;
@@ -487,8 +487,7 @@ static void GenerateTerrain(int type, int flag)
y = (r >> MapLogX()) & MapMaxY();
- if (x < 2 || y < 2)
- return;
+ if (x < 2 || y < 2) return;
direction = GB(r, 22, 2);
if (direction & 1) {
@@ -524,11 +523,8 @@ static void GenerateTerrain(int type, int flag)
}
}
- if (x + w >= MapMaxX() - 1)
- return;
-
- if (y + h >= MapMaxY() - 1)
- return;
+ if (x + w >= MapMaxX() - 1) return;
+ if (y + h >= MapMaxY() - 1) return;
tile = &_m[TileXY(x, y)];