(svn r11407) -Fix: do not allow building of tram-tracks when they are not available (SmatZ)
This commit is contained in:
@@ -19,6 +19,7 @@
|
||||
#include "viewport.h"
|
||||
#include "gfx.h"
|
||||
#include "player.h"
|
||||
#include "road.h"
|
||||
#include "command.h"
|
||||
#include "news.h"
|
||||
#include "town.h"
|
||||
@@ -930,7 +931,7 @@ static void ToolbarBuildRoadClick(Window *w)
|
||||
{
|
||||
const Player *p = GetPlayer(_local_player);
|
||||
/* The standard road button is *always* available */
|
||||
Window *w2 = PopupMainToolbMenu(w, 20, STR_180A_ROAD_CONSTRUCTION, 2, ~(p->avail_roadtypes | 1));
|
||||
Window *w2 = PopupMainToolbMenu(w, 20, STR_180A_ROAD_CONSTRUCTION, 2, ~(p->avail_roadtypes | ROADTYPES_ROAD));
|
||||
WP(w2, menu_d).sel_index = _last_built_roadtype;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user