equal
deleted
inserted
replaced
979 * because multistop depends on vehicles actually reaching the exact |
979 * because multistop depends on vehicles actually reaching the exact |
980 * dest_tile, not just any stop of that station. |
980 * dest_tile, not just any stop of that station. |
981 * So only for train orders to stations we fill fstd->station_index, for all |
981 * So only for train orders to stations we fill fstd->station_index, for all |
982 * others only dest_coords */ |
982 * others only dest_coords */ |
983 if (v->current_order.IsType(OT_GOTO_STATION) && v->type == VEH_TRAIN) { |
983 if (v->current_order.IsType(OT_GOTO_STATION) && v->type == VEH_TRAIN) { |
984 fstd->station_index = v->current_order.dest; |
984 fstd->station_index = v->current_order.GetDestination(); |
985 /* Let's take the closest tile of the station as our target for trains */ |
985 /* Let's take the closest tile of the station as our target for trains */ |
986 fstd->dest_coords = CalcClosestStationTile(v->current_order.dest, v->tile); |
986 fstd->dest_coords = CalcClosestStationTile(fstd->station_index, v->tile); |
987 } else { |
987 } else { |
988 fstd->dest_coords = v->dest_tile; |
988 fstd->dest_coords = v->dest_tile; |
989 fstd->station_index = INVALID_STATION; |
989 fstd->station_index = INVALID_STATION; |
990 } |
990 } |
991 } |
991 } |