diff src/vehicle_gui.cpp @ 8836:890a77315801 draft

(svn r12584) -Codechange: do not access the order type directly.
author rubidium <rubidium@openttd.org>
date Sat, 05 Apr 2008 23:36:54 +0000 (2008-04-05)
parents e2d4956b7251
children c3d2f0eb69a1
line wrap: on
line diff
--- a/src/vehicle_gui.cpp
+++ b/src/vehicle_gui.cpp
@@ -917,7 +917,7 @@
 		if (sel == 0) DrawString(x - 6, y, STR_SMALL_RIGHT_ARROW, TC_BLACK);
 		sel--;
 
-		if (order->type == OT_GOTO_STATION) {
+		if (order->IsType(OT_GOTO_STATION)) {
 			if (v->type == VEH_SHIP && GetStation(order->dest)->IsBuoy()) continue;
 
 			SetDParam(0, order->dest);
@@ -1952,7 +1952,7 @@
 			str = STR_8861_STOPPED;
 		}
 	} else { // vehicle is in a "normal" state, show current order
-		switch (v->current_order.type) {
+		switch (v->current_order.GetType()) {
 			case OT_GOTO_STATION: {
 				SetDParam(0, v->current_order.dest);
 				SetDParam(1, v->GetDisplaySpeed());