changeset 17874:b3544f85de6c draft

(svn r22670) -Change: Do not spawn explosion effects when bulldozing in paused mode. They block the view.
author frosch <frosch@openttd.org>
date Sun, 17 Jul 2011 16:09:38 +0000
parents 9c497cde37af
children a99eac34ad6a
files src/landscape.cpp
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/landscape.cpp
+++ b/src/landscape.cpp
@@ -690,9 +690,10 @@
 			}
 			DoCommand(t, 0, 0, flags, CMD_LANDSCAPE_CLEAR);
 
-			/* draw explosion animation... */
+			/* draw explosion animation...
+			 * Disable explosions when game is paused. Looks silly and blocks the view. */
 			TileIndex off = t - ta.tile;
-			if ((TileX(off) == 0 || TileX(off) == ta.w - 1U) && (TileY(off) == 0 || TileY(off) == ta.h - 1U)) {
+			if ((TileX(off) == 0 || TileX(off) == ta.w - 1U) && (TileY(off) == 0 || TileY(off) == ta.h - 1U) && _pause_mode == PM_UNPAUSED) {
 				/* big explosion in each corner, or small explosion for single tiles */
 				CreateEffectVehicleAbove(TileX(t) * TILE_SIZE + TILE_SIZE / 2, TileY(t) * TILE_SIZE + TILE_SIZE / 2, 2,
 					ta.w == 1 && ta.h == 1 ? EV_EXPLOSION_SMALL : EV_EXPLOSION_LARGE