src/aircraft_cmd.cpp
changeset 6020 a7463b7eb894
parent 6011 04cd7c7f1d64
child 6024 37e72f8f6a99
--- a/src/aircraft_cmd.cpp	Thu Feb 15 07:08:22 2007 +0000
+++ b/src/aircraft_cmd.cpp	Thu Feb 15 07:43:06 2007 +0000
@@ -969,7 +969,8 @@
 	}
 
 	// get airport moving data
-	const AirportMovingData *amd = GetAirport(st->airport_type)->MovingData(v->u.air.pos);
+	const AirportFTAClass *afc = GetAirport(st->airport_type);
+	const AirportMovingData *amd = afc->MovingData(v->u.air.pos);
 
 	// Helicopter raise
 	if (amd->flag & AMED_HELI_RAISE) {
@@ -1011,9 +1012,7 @@
 			v->tile = st->airport_tile;
 
 			// Find altitude of landing position.
-			z = GetSlopeZ(x, y) + 1;
-			if (st->airport_type == AT_OILRIG) z += 54;
-			if (st->airport_type == AT_HELIPORT) z += 60;
+			z = GetSlopeZ(x, y) + 1 + afc->delta_z;
 
 			if (z == v->z_pos) {
 				u = v->next->next;