summaryrefslogtreecommitdiff
path: root/src/terraform_cmd.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-07-26 21:50:30 +0000
committerrubidium <rubidium@openttd.org>2009-07-26 21:50:30 +0000
commit2ec12a3f587f4271a2d8ba5e22af233e1094e321 (patch)
tree114688ff4bf43f5c94891a3fa67b5b172d187323 /src/terraform_cmd.cpp
parent47a37b6093c3bb93dba81e4d3440c4098699a849 (diff)
downloadopenttd-2ec12a3f587f4271a2d8ba5e22af233e1094e321.tar.xz
(svn r16966) -Codechange: BEGIN_TILE_LOOP and END_TILE_LOOP reworked into TILE_LOOP, which means no more duplication of parameters between BEGIN_TILE_LOOP and END_TILE_LOOP
Diffstat (limited to 'src/terraform_cmd.cpp')
-rw-r--r--src/terraform_cmd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/terraform_cmd.cpp b/src/terraform_cmd.cpp
index adbbdedf7..34b7e19fa 100644
--- a/src/terraform_cmd.cpp
+++ b/src/terraform_cmd.cpp
@@ -385,7 +385,7 @@ CommandCost CmdLevelLand(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32
Money money = GetAvailableMoneyForCommand();
CommandCost cost(EXPENSES_CONSTRUCTION);
- BEGIN_TILE_LOOP(tile2, size_x, size_y, tile) {
+ TILE_LOOP(tile2, size_x, size_y, tile) {
uint curh = TileHeight(tile2);
while (curh != h) {
CommandCost ret = DoCommand(tile2, SLOPE_N, (curh > h) ? 0 : 1, flags & ~DC_EXEC, CMD_TERRAFORM_LAND);
@@ -403,7 +403,7 @@ CommandCost CmdLevelLand(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32
cost.AddCost(ret);
curh += (curh > h) ? -1 : 1;
}
- } END_TILE_LOOP(tile2, size_x, size_y, tile)
+ }
return (cost.GetCost() == 0) ? CMD_ERROR : cost;
}