summaryrefslogtreecommitdiff
path: root/aircraft_cmd.c
diff options
context:
space:
mode:
authorbjarni <bjarni@openttd.org>2005-01-27 21:00:05 +0000
committerbjarni <bjarni@openttd.org>2005-01-27 21:00:05 +0000
commit99338d278da52e2f71fe8c4d3f05449a1ad24144 (patch)
tree5bdf21fd520f2315aba284830d98f9db10e8e388 /aircraft_cmd.c
parent1ae9e7b4480865289c2793ac1f9bad53090d5d40 (diff)
downloadopenttd-99338d278da52e2f71fe8c4d3f05449a1ad24144.tar.xz
(svn r1700) - Fix: Hacked clients can no longer be used to build vehicles that are not available yet (Hackykid)
Diffstat (limited to 'aircraft_cmd.c')
-rw-r--r--aircraft_cmd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/aircraft_cmd.c b/aircraft_cmd.c
index 46a846d57..7525b6a6c 100644
--- a/aircraft_cmd.c
+++ b/aircraft_cmd.c
@@ -161,6 +161,8 @@ int32 CmdBuildAircraft(int x, int y, uint32 flags, uint32 p1, uint32 p2)
const AircraftVehicleInfo *avi = AircraftVehInfo(p1);
Engine *e;
+ if (!(IsEngineBuildable(p1, VEH_Aircraft))) return CMD_ERROR;
+
SET_EXPENSES_TYPE(EXPENSES_NEW_VEHICLES);
value = EstimateAircraftCost(p1);