summaryrefslogtreecommitdiff
path: root/src/economy.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-06-18 21:00:14 +0000
committerrubidium <rubidium@openttd.org>2007-06-18 21:00:14 +0000
commit7a72dcb3b57b70214c4d402be89f9b1dd158d790 (patch)
tree1ba3bbf25a5886a7f40a02d3403d53c57e634d75 /src/economy.cpp
parent26e9b5ca5f0eafae421a640ea4e4753d6ac7ec0e (diff)
downloadopenttd-7a72dcb3b57b70214c4d402be89f9b1dd158d790.tar.xz
(svn r10207) -Codechange: remove the redundant player_money in favour of the money64, which is now renamed to player_money.
Diffstat (limited to 'src/economy.cpp')
-rw-r--r--src/economy.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/economy.cpp b/src/economy.cpp
index 2152823ca..aa2be9247 100644
--- a/src/economy.cpp
+++ b/src/economy.cpp
@@ -88,7 +88,7 @@ int64 CalculateCompanyValue(const Player* p)
}
}
- value += p->money64 - p->current_loan; // add real money value
+ value += p->player_money - p->current_loan; // add real money value
return max(value, 1LL);
}
@@ -287,8 +287,7 @@ void ChangeOwnershipOfPlayerItems(PlayerID old_player, PlayerID new_player)
* removing his/her property doesn't fail because of lack of money.
* Not too drastically though, because it could overflow */
if (new_player == PLAYER_SPECTATOR) {
- GetPlayer(old_player)->money64 = MAX_UVALUE(uint64) >>2; // jackpot ;p
- UpdatePlayerMoney32(GetPlayer(old_player));
+ GetPlayer(old_player)->player_money = MAX_UVALUE(uint64) >> 2; // jackpot ;p
}
if (new_player == PLAYER_SPECTATOR) {
@@ -1788,9 +1787,8 @@ static void DoAcquireCompany(Player *p)
for (i = 0; i != 4; i++) {
if (p->share_owners[i] != PLAYER_SPECTATOR) {
owner = GetPlayer(p->share_owners[i]);
- owner->money64 += value;
+ owner->player_money += value;
owner->yearly_expenses[0][EXPENSES_OTHER] += value;
- UpdatePlayerMoney32(owner);
}
}