summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-12-12 15:20:54 +0000
committerrubidium <rubidium@openttd.org>2010-12-12 15:20:54 +0000
commit90e247c84dc1b286096555ae50e2cd0887bd81e1 (patch)
tree241dda35e45c6b8261c0370b686fb781d87b7944
parentcd7b23b0f43db92587de109b252496a2ee4b58c7 (diff)
downloadopenttd-90e247c84dc1b286096555ae50e2cd0887bd81e1.tar.xz
(svn r21480) -Change [FS#4292]: make it possible to start actions that require selecting stuff (landscaping, vehicle cloning, etc) in the viewport while paused. As side-effect you'll get an error message explaining the command can't be executed because the game is paused instead of seemingly nothing happening when you click. Addition side effect of this is that you can make use of the measurement tooltip while paused
-rw-r--r--src/window.cpp30
1 files changed, 0 insertions, 30 deletions
diff --git a/src/window.cpp b/src/window.cpp
index df7771633..5e0242839 100644
--- a/src/window.cpp
+++ b/src/window.cpp
@@ -2213,36 +2213,6 @@ static void MouseLoop(MouseClick click, int mousewheel)
case MC_DOUBLE_LEFT:
case MC_LEFT:
DEBUG(misc, 2, "Cursor: 0x%X (%d)", _cursor.sprite, _cursor.sprite);
- if (_thd.place_mode != HT_NONE && _pause_mode != PM_UNPAUSED && _game_mode != GM_EDITOR) {
- switch (_settings_game.construction.command_pause_level) {
- case CMDPL_ALL_ACTIONS:
- /* We allow all actions. */
- break;
-
- case CMDPL_NO_LANDSCAPING:
- if (_cursor.sprite == SPR_CURSOR_CLONE_TRAIN ||
- _cursor.sprite == SPR_CURSOR_CLONE_ROADVEH ||
- _cursor.sprite == SPR_CURSOR_CLONE_SHIP ||
- _cursor.sprite == SPR_CURSOR_CLONE_AIRPLANE) {
- /* Cloning is allowed. */
- break;
- }
- /* FALL THROUGH */
- case CMDPL_NO_CONSTRUCTION:
- if (_cursor.sprite == SPR_CURSOR_SIGN ||
- (_cursor.sprite >= SPR_CURSOR_PICKSTATION_FIRST && _cursor.sprite <= SPR_CURSOR_PICKSTATION_LAST)) {
- /* Building signs or making orders is allowed. */
- break;
- }
- /* FALL THROUGH */
- case CMDPL_NO_ACTIONS:
- if (_cursor.sprite == SPR_CURSOR_QUERY) break;
-
- /* All other ones are not allowed to build. */
- return;
- }
- }
-
if (!HandleViewportClicked(vp, x, y) &&
!(w->flags4 & WF_DISABLE_VP_SCROLL) &&
_settings_client.gui.left_mouse_btn_scrolling) {