summaryrefslogtreecommitdiff
path: root/roadveh_cmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'roadveh_cmd.c')
-rw-r--r--roadveh_cmd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/roadveh_cmd.c b/roadveh_cmd.c
index c78aa79d8..f2a5c88c8 100644
--- a/roadveh_cmd.c
+++ b/roadveh_cmd.c
@@ -115,6 +115,8 @@ int32 CmdBuildRoadVeh(int x, int y, uint32 flags, uint32 p1, uint32 p2)
uint tile = TILE_FROM_XY(x,y);
Engine *e;
+ if (!(IsEngineBuildable(p1, VEH_Road))) return CMD_ERROR;
+
SET_EXPENSES_TYPE(EXPENSES_NEW_VEHICLES);
cost = EstimateRoadVehCost(p1);