1
0
Fork 0

(svn r19684) -Fix [FS#3779]: don't show an error message when trying to give another client an amount of 0 money

release/1.1
yexo 2010-04-20 18:02:08 +00:00
parent dba2a57b0d
commit 879057de25
1 changed files with 1 additions and 1 deletions

View File

@ -223,7 +223,7 @@ CommandCost CmdGiveMoney(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32
CommandCost amount(EXPENSES_OTHER, min((Money)p1, (Money)20000000LL)); CommandCost amount(EXPENSES_OTHER, min((Money)p1, (Money)20000000LL));
/* You can only transfer funds that is in excess of your loan */ /* You can only transfer funds that is in excess of your loan */
if (c->money - c->current_loan < amount.GetCost() || amount.GetCost() <= 0) return CMD_ERROR; if (c->money - c->current_loan < amount.GetCost() || amount.GetCost() < 0) return CMD_ERROR;
if (!_networking || !Company::IsValidID((CompanyID)p2)) return CMD_ERROR; if (!_networking || !Company::IsValidID((CompanyID)p2)) return CMD_ERROR;
if (flags & DC_EXEC) { if (flags & DC_EXEC) {