internal static void MoveCar(Train Train, int CarIndex, double Delta, double TimeElapsed)
{
if (Train.State != TrainState.Disposed)
{
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].FrontAxle.Follower, Train.Cars[CarIndex].FrontAxle.Follower.TrackPosition + Delta, true, true);
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].FrontBogie.FrontAxle.Follower, Train.Cars[CarIndex].FrontBogie.FrontAxle.Follower.TrackPosition + Delta, true, true);
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].FrontBogie.RearAxle.Follower, Train.Cars[CarIndex].FrontBogie.RearAxle.Follower.TrackPosition + Delta, true, true);
if (Train.State != TrainState.Disposed)
{
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].RearAxle.Follower, Train.Cars[CarIndex].RearAxle.Follower.TrackPosition + Delta, true, true);
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].RearBogie.FrontAxle.Follower, Train.Cars[CarIndex].RearBogie.FrontAxle.Follower.TrackPosition + Delta, true, true);
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].RearBogie.RearAxle.Follower, Train.Cars[CarIndex].RearBogie.RearAxle.Follower.TrackPosition + Delta, true, true);
if (Train.State != TrainState.Disposed)
{
TrackManager.UpdateTrackFollower(ref Train.Cars[CarIndex].BeaconReceiver, Train.Cars[CarIndex].BeaconReceiver.TrackPosition + Delta, true, true);
}
}
}
}