Time::TimeDelta TrainRoutePlanner::TrainRoutingState::get_time_to_next_track() const
{
- return ((track->get_type().get_path_length(path)-offset)/info->speed)*Time::sec+delay;
+ return ((occupied_tracks->path_length-offset)/info->speed)*Time::sec+delay;
}
Time::TimeDelta TrainRoutePlanner::TrainRoutingState::get_time_to_pass(Track &trk) const
TrackIter iter = track.reverse(path);
remaining_estimate = info->metrics[waypoint]->get_distance_from(*iter.track(), iter.entry());
if(remaining_estimate>=0)
- remaining_estimate += track->get_type().get_path_length(path)-offset;
+ remaining_estimate += occupied_tracks->path_length-offset;
}
bool TrainRoutePlanner::TrainRoutingState::is_viable() const