train_gui.c
changeset 555 02df8a1b7f33
parent 543 946badd71033
child 567 e63b977925f7
equal deleted inserted replaced
554:a4ba0fbbf018 555:02df8a1b7f33
   776 			} else {
   776 			} else {
   777 				SetDParam(0, v->u.rail.last_speed * 10 >> 4);
   777 				SetDParam(0, v->u.rail.last_speed * 10 >> 4);
   778 				str = STR_TRAIN_STOPPING + _patches.vehicle_speed;
   778 				str = STR_TRAIN_STOPPING + _patches.vehicle_speed;
   779 			}
   779 			}
   780 		} else {
   780 		} else {
   781 			switch(v->next_order & OT_MASK) {
   781 			switch (v->current_order.type) {
   782 			case OT_GOTO_STATION: {
   782 			case OT_GOTO_STATION: {
   783 				str = STR_HEADING_FOR_STATION + _patches.vehicle_speed;
   783 				str = STR_HEADING_FOR_STATION + _patches.vehicle_speed;
   784 				SetDParam(0, v->next_order_param);
   784 				SetDParam(0, v->current_order.station);
   785 				SetDParam(1, v->u.rail.last_speed * 10 >> 4);
   785 				SetDParam(1, v->u.rail.last_speed * 10 >> 4);
   786 			} break;
   786 			} break;
   787 
   787 
   788 			case OT_GOTO_DEPOT: {
   788 			case OT_GOTO_DEPOT: {
   789 				Depot *dep = &_depots[v->next_order_param];
   789 				Depot *dep = &_depots[v->current_order.station];
   790 				SetDParam(0, dep->town_index);
   790 				SetDParam(0, dep->town_index);
   791 				str = STR_HEADING_FOR_TRAIN_DEPOT + _patches.vehicle_speed;
   791 				str = STR_HEADING_FOR_TRAIN_DEPOT + _patches.vehicle_speed;
   792 				SetDParam(1, v->u.rail.last_speed * 10 >> 4);
   792 				SetDParam(1, v->u.rail.last_speed * 10 >> 4);
   793 			} break;
   793 			} break;
   794 
   794 
   796 			case OT_LEAVESTATION:
   796 			case OT_LEAVESTATION:
   797 				str = STR_882F_LOADING_UNLOADING;
   797 				str = STR_882F_LOADING_UNLOADING;
   798 				break;
   798 				break;
   799 
   799 
   800 			case OT_GOTO_WAYPOINT: {
   800 			case OT_GOTO_WAYPOINT: {
   801 				SetDParam(0, v->next_order_param);
   801 				SetDParam(0, v->current_order.station);
   802 				str = STR_HEADING_FOR_WAYPOINT + _patches.vehicle_speed;
   802 				str = STR_HEADING_FOR_WAYPOINT + _patches.vehicle_speed;
   803 				SetDParam(1, v->u.rail.last_speed * 10 >> 4);
   803 				SetDParam(1, v->u.rail.last_speed * 10 >> 4);
   804 				break;
   804 				break;
   805 			}
   805 			}
   806 
   806