mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-03 21:06:58 +00:00
(svn r19684) -Fix [FS#3779]: don't show an error message when trying to give another client an amount of 0 money
This commit is contained in:
parent
dba2a57b0d
commit
879057de25
@ -223,7 +223,7 @@ CommandCost CmdGiveMoney(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32
|
||||
CommandCost amount(EXPENSES_OTHER, min((Money)p1, (Money)20000000LL));
|
||||
|
||||
/* 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 (flags & DC_EXEC) {
|
||||
|
Loading…
Reference in New Issue
Block a user