Changeset - r16752:5542d9a39cb2
[Not reviewed]
master
0 1 0
rubidium - 14 years ago 2010-12-13 11:30:22
rubidium@openttd.org
(svn r21495) -Codechange: don't hide a local variable
1 file changed with 4 insertions and 4 deletions:
0 comments (0 inline, 0 general)
src/terraform_cmd.cpp
Show inline comments
 
@@ -411,10 +411,10 @@ CommandCost CmdLevelLand(TileIndex tile,
 
	bool had_success = false;
 

	
 
	TileArea ta(tile, p1);
 
	TILE_AREA_LOOP(tile, ta) {
 
		uint curh = TileHeight(tile);
 
	TILE_AREA_LOOP(t, ta) {
 
		uint curh = TileHeight(t);
 
		while (curh != h) {
 
			CommandCost ret = DoCommand(tile, SLOPE_N, (curh > h) ? 0 : 1, flags & ~DC_EXEC, CMD_TERRAFORM_LAND);
 
			CommandCost ret = DoCommand(t, SLOPE_N, (curh > h) ? 0 : 1, flags & ~DC_EXEC, CMD_TERRAFORM_LAND);
 
			if (ret.Failed()) {
 
				last_error = ret;
 
				break;
 
@@ -426,7 +426,7 @@ CommandCost CmdLevelLand(TileIndex tile,
 
					_additional_cash_required = ret.GetCost();
 
					return cost;
 
				}
 
				DoCommand(tile, SLOPE_N, (curh > h) ? 0 : 1, flags, CMD_TERRAFORM_LAND);
 
				DoCommand(t, SLOPE_N, (curh > h) ? 0 : 1, flags, CMD_TERRAFORM_LAND);
 
			}
 

	
 
			cost.AddCost(ret);
0 comments (0 inline, 0 general)