(svn r11021) -Fix [FS#1175]: do not display income/expenses when they do not belong to a "valid" tile, like the money cheat/giving money.
authorrubidium
Fri, 31 Aug 2007 17:43:29 +0000
changeset 7506 93b2cbcce3d6
parent 7505 55e7acbf7a69
child 7507 36bb5300a128
(svn r11021) -Fix [FS#1175]: do not display income/expenses when they do not belong to a "valid" tile, like the money cheat/giving money.
src/command.cpp
--- a/src/command.cpp	Fri Aug 31 17:38:29 2007 +0000
+++ b/src/command.cpp	Fri Aug 31 17:43:29 2007 +0000
@@ -570,7 +570,7 @@
 	SubtractMoneyFromPlayer(res2);
 
 	if (IsLocalPlayer() && _game_mode != GM_EDITOR) {
-		if (res2.GetCost() != 0) ShowCostOrIncomeAnimation(x, y, GetSlopeZ(x, y), res2.GetCost());
+		if (res2.GetCost() != 0 && tile != 0) ShowCostOrIncomeAnimation(x, y, GetSlopeZ(x, y), res2.GetCost());
 		if (_additional_cash_required != 0) {
 			SetDParam(0, _additional_cash_required);
 			if (my_cmd) ShowErrorMessage(STR_0003_NOT_ENOUGH_CASH_REQUIRES, error_part1, x, y);