diff options
author | rubidium <rubidium@openttd.org> | 2008-07-17 20:13:01 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-07-17 20:13:01 +0000 |
commit | 6898a76c5f80ef1aa65106f98d5e36002bc0ddda (patch) | |
tree | ca5029fca4c5aee49145e4bd3e3f0f81df8ccabc /src/economy.cpp | |
parent | 83824f4c86b01c93465c0ab71dc84e03f9883e5f (diff) | |
download | openttd-6898a76c5f80ef1aa65106f98d5e36002bc0ddda.tar.xz |
(svn r13719) -Codechange: rename IsValidPlayer to IsValidPlayerID in line with all other structs/classes that are in a pool.
Diffstat (limited to 'src/economy.cpp')
-rw-r--r-- | src/economy.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/economy.cpp b/src/economy.cpp index 30180cee2..a42bd3bab 100644 --- a/src/economy.cpp +++ b/src/economy.cpp @@ -1784,7 +1784,7 @@ CommandCost CmdBuyShareInCompany(TileIndex tile, uint32 flags, uint32 p1, uint32 /* Check if buying shares is allowed (protection against modified clients) */ /* Cannot buy own shares */ - if (!IsValidPlayer((PlayerID)p1) || !_settings_game.economy.allow_shares || _current_player == (PlayerID)p1) return CMD_ERROR; + if (!IsValidPlayerID((PlayerID)p1) || !_settings_game.economy.allow_shares || _current_player == (PlayerID)p1) return CMD_ERROR; p = GetPlayer((PlayerID)p1); @@ -1833,7 +1833,7 @@ CommandCost CmdSellShareInCompany(TileIndex tile, uint32 flags, uint32 p1, uint3 /* Check if selling shares is allowed (protection against modified clients) */ /* Cannot sell own shares */ - if (!IsValidPlayer((PlayerID)p1) || !_settings_game.economy.allow_shares || _current_player == (PlayerID)p1) return CMD_ERROR; + if (!IsValidPlayerID((PlayerID)p1) || !_settings_game.economy.allow_shares || _current_player == (PlayerID)p1) return CMD_ERROR; p = GetPlayer((PlayerID)p1); @@ -1871,7 +1871,7 @@ CommandCost CmdBuyCompany(TileIndex tile, uint32 flags, uint32 p1, uint32 p2) PlayerID pid = (PlayerID)p1; /* Disable takeovers in multiplayer games */ - if (!IsValidPlayer(pid) || _networking) return CMD_ERROR; + if (!IsValidPlayerID(pid) || _networking) return CMD_ERROR; /* Do not allow players to take over themselves */ if (pid == _current_player) return CMD_ERROR; |