mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-04 13:23:46 +00:00
(svn r6740) -Fix: if a rail is not available, don't show toolbar even with hotkey 'A'
This commit is contained in:
parent
e262669eb6
commit
d6c21e4d71
@ -590,6 +590,7 @@ void ShowBuildRailToolbar(RailType railtype, int button)
|
||||
Window *w;
|
||||
|
||||
if (_current_player == OWNER_SPECTATOR) return;
|
||||
if (!ValParamRailtype(railtype)) return;
|
||||
|
||||
// don't recreate the window if we're clicking on a button and the window exists.
|
||||
if (button < 0 || !(w = FindWindowById(WC_BUILD_TOOLBAR, 0)) || w->wndproc != BuildRailToolbWndProc) {
|
||||
|
Loading…
Reference in New Issue
Block a user