src/waypoint.cpp
branchnoai
changeset 9869 6404afe43575
parent 9837 c9ec4f82e0d0
child 10142 56ee7da4ad56
equal deleted inserted replaced
9868:3998f2e73dda 9869:6404afe43575
   234 		 * have the old waypoint in their orders. */
   234 		 * have the old waypoint in their orders. */
   235 		Vehicle *v;
   235 		Vehicle *v;
   236 		FOR_ALL_VEHICLES(v) {
   236 		FOR_ALL_VEHICLES(v) {
   237 			if (v->type == VEH_TRAIN &&
   237 			if (v->type == VEH_TRAIN &&
   238 					v->First() == v &&
   238 					v->First() == v &&
   239 					v->current_order.type == OT_GOTO_WAYPOINT &&
   239 					v->current_order.IsType(OT_GOTO_WAYPOINT) &&
   240 					v->dest_tile == wp->xy) {
   240 					v->dest_tile == wp->xy) {
   241 				v->dest_tile = tile;
   241 				v->dest_tile = tile;
   242 			}
   242 			}
   243 		}
   243 		}
   244 
   244