summaryrefslogtreecommitdiff
path: root/src/unmovable_cmd.cpp
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2008-08-25 16:10:34 +0000
committerbelugas <belugas@openttd.org>2008-08-25 16:10:34 +0000
commit08898f69bebd4ed5fc866aeb31406cc512ed7fcf (patch)
tree939b2bf0ef664550aa207ba7a014be3c9614adb9 /src/unmovable_cmd.cpp
parentcf52b683c0a478b113bd25893f49554906edb32f (diff)
downloadopenttd-08898f69bebd4ed5fc866aeb31406cc512ed7fcf.tar.xz
(svn r14169) -Codechange: rename location_of_house for location_of_HQ, which is more exact and less subject to interpretation
Diffstat (limited to 'src/unmovable_cmd.cpp')
-rw-r--r--src/unmovable_cmd.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/unmovable_cmd.cpp b/src/unmovable_cmd.cpp
index 38098399c..9e8a8ad93 100644
--- a/src/unmovable_cmd.cpp
+++ b/src/unmovable_cmd.cpp
@@ -45,13 +45,13 @@ static CommandCost DestroyCompanyHQ(PlayerID pid, uint32 flags)
Player *p = GetPlayer(pid);
if (flags & DC_EXEC) {
- TileIndex t = p->location_of_house;
+ TileIndex t = p->location_of_HQ;
DoClearSquare(t + TileDiffXY(0, 0));
DoClearSquare(t + TileDiffXY(0, 1));
DoClearSquare(t + TileDiffXY(1, 0));
DoClearSquare(t + TileDiffXY(1, 1));
- p->location_of_house = 0; // reset HQ position
+ p->location_of_HQ = 0; // reset HQ position
InvalidateWindow(WC_COMPANY, pid);
}
@@ -62,7 +62,7 @@ static CommandCost DestroyCompanyHQ(PlayerID pid, uint32 flags)
void UpdateCompanyHQ(Player *p, uint score)
{
byte val;
- TileIndex tile = p->location_of_house;
+ TileIndex tile = p->location_of_HQ;
if (tile == 0) return;
@@ -96,14 +96,14 @@ CommandCost CmdBuildCompanyHQ(TileIndex tile, uint32 flags, uint32 p1, uint32 p2
cost = CheckFlatLandBelow(tile, 2, 2, flags, 0, NULL);
if (CmdFailed(cost)) return cost;
- if (p->location_of_house != 0) { // Moving HQ
+ if (p->location_of_HQ != 0) { // Moving HQ
cost.AddCost(DestroyCompanyHQ(_current_player, flags));
}
if (flags & DC_EXEC) {
int score = UpdateCompanyRatingAndValue(p, false);
- p->location_of_house = tile;
+ p->location_of_HQ = tile;
MakeCompanyHQ(tile, _current_player);