diff options
author | rubidium <rubidium@openttd.org> | 2009-03-15 00:32:18 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2009-03-15 00:32:18 +0000 |
commit | b25a4f8231f3ded44038ea454a3d4c6a2dc9217d (patch) | |
tree | 776122508c686680b9c97f37ba3cb92ef905d67f /src/economy.cpp | |
parent | d72273d1f3b55df0e301408d630f24ef92ea8479 (diff) | |
download | openttd-b25a4f8231f3ded44038ea454a3d4c6a2dc9217d.tar.xz |
(svn r15718) -Cleanup: apply some comment coding style on the rest of the sources too
Diffstat (limited to 'src/economy.cpp')
-rw-r--r-- | src/economy.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/economy.cpp b/src/economy.cpp index 6cfffa422..59d6997fc 100644 --- a/src/economy.cpp +++ b/src/economy.cpp @@ -332,7 +332,7 @@ void ChangeOwnershipOfCompanyItems(Owner old_owner, Owner new_owner) if (new_owner != INVALID_OWNER) { if (HasBit(t->have_ratings, old_owner)) { if (HasBit(t->have_ratings, new_owner)) { - // use max of the two ratings. + /* use max of the two ratings. */ t->ratings[new_owner] = max(t->ratings[new_owner], t->ratings[old_owner]); } else { SetBit(t->have_ratings, new_owner); @@ -1889,8 +1889,8 @@ CommandCost CmdBuyShareInCompany(TileIndex tile, DoCommandFlag flags, uint32 p1, { CommandCost cost(EXPENSES_OTHER); - /* Check if buying shares is allowed (protection against modified clients) */ - /* Cannot buy own shares */ + /* Check if buying shares is allowed (protection against modified clients) + * Cannot buy own shares */ if (!IsValidCompanyID((CompanyID)p1) || !_settings_game.economy.allow_shares || _current_company == (CompanyID)p1) return CMD_ERROR; Company *c = GetCompany((CompanyID)p1); @@ -1909,7 +1909,7 @@ CommandCost CmdBuyShareInCompany(TileIndex tile, DoCommandFlag flags, uint32 p1, OwnerByte *b = c->share_owners; int i; - while (*b != COMPANY_SPECTATOR) b++; /* share owners is guaranteed to contain at least one COMPANY_SPECTATOR */ + while (*b != COMPANY_SPECTATOR) b++; // share owners is guaranteed to contain at least one COMPANY_SPECTATOR *b = _current_company; for (i = 0; c->share_owners[i] == _current_company;) { @@ -1932,8 +1932,8 @@ CommandCost CmdBuyShareInCompany(TileIndex tile, DoCommandFlag flags, uint32 p1, */ CommandCost CmdSellShareInCompany(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32 p2, const char *text) { - /* Check if selling shares is allowed (protection against modified clients) */ - /* Cannot sell own shares */ + /* Check if selling shares is allowed (protection against modified clients) + * Cannot sell own shares */ if (!IsValidCompanyID((CompanyID)p1) || !_settings_game.economy.allow_shares || _current_company == (CompanyID)p1) return CMD_ERROR; Company *c = GetCompany((CompanyID)p1); |