summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2009-02-05 03:17:30 +0000
committerbelugas <belugas@openttd.org>2009-02-05 03:17:30 +0000
commit63cc1bd21f90a6099824178d59e402eb19eeffae (patch)
tree196acbabdba5bdc529470660c1b4f7a0b2338fa2
parentf936afa64ab6074976a494ce377524d7b06d8853 (diff)
downloadopenttd-63cc1bd21f90a6099824178d59e402eb19eeffae.tar.xz
(svn r15349) -Codechange: no need to call a function when we know there is not going to be any change to the returned result
-rw-r--r--src/unmovable_cmd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/unmovable_cmd.cpp b/src/unmovable_cmd.cpp
index ce7e09d26..3e45b6d22 100644
--- a/src/unmovable_cmd.cpp
+++ b/src/unmovable_cmd.cpp
@@ -41,7 +41,7 @@ static CommandCost DestroyCompanyHQ(CompanyID cid, uint32 flags)
if (flags & DC_EXEC) {
TileIndex t = c->location_of_HQ;
- DoClearSquare(t + TileDiffXY(0, 0));
+ DoClearSquare(t);
DoClearSquare(t + TileDiffXY(0, 1));
DoClearSquare(t + TileDiffXY(1, 0));
DoClearSquare(t + TileDiffXY(1, 1));
@@ -68,7 +68,7 @@ void UpdateCompanyHQ(Company *c, uint score)
EnlargeCompanyHQ(tile, val);
- MarkTileDirtyByTile(tile + TileDiffXY(0, 0));
+ MarkTileDirtyByTile(tile);
MarkTileDirtyByTile(tile + TileDiffXY(0, 1));
MarkTileDirtyByTile(tile + TileDiffXY(1, 0));
MarkTileDirtyByTile(tile + TileDiffXY(1, 1));