equal
deleted
inserted
replaced
280 if (!IsHangarTile(tile) || !IsTileOwner(tile, _current_player)) return CMD_ERROR; |
280 if (!IsHangarTile(tile) || !IsTileOwner(tile, _current_player)) return CMD_ERROR; |
281 |
281 |
282 SET_EXPENSES_TYPE(EXPENSES_NEW_VEHICLES); |
282 SET_EXPENSES_TYPE(EXPENSES_NEW_VEHICLES); |
283 |
283 |
284 /* Prevent building aircraft types at places which can't handle them */ |
284 /* Prevent building aircraft types at places which can't handle them */ |
285 if (!IsAircraftBuildableAtStation(p1, tile)) return CMD_ERROR; |
285 if (!CanAircraftUseStation(p1, tile)) return CMD_ERROR; |
286 |
286 |
287 /* Allocate 2 or 3 vehicle structs, depending on type |
287 /* Allocate 2 or 3 vehicle structs, depending on type |
288 * vl[0] = aircraft, vl[1] = shadow, [vl[2] = rotor] */ |
288 * vl[0] = aircraft, vl[1] = shadow, [vl[2] = rotor] */ |
289 Vehicle *vl[3]; |
289 Vehicle *vl[3]; |
290 if (!Vehicle::AllocateList(vl, avi->subtype & AIR_CTOL ? 2 : 3)) { |
290 if (!Vehicle::AllocateList(vl, avi->subtype & AIR_CTOL ? 2 : 3)) { |