Commit 3a0945f2 authored by Sophie Schönherr's avatar Sophie Schönherr
Browse files

Fixed infinity-loop on simulation end

parent 5f9bb1f0
...@@ -279,7 +279,9 @@ public class VehicleMovementModel implements MovementModel, EventHandler, Future ...@@ -279,7 +279,9 @@ public class VehicleMovementModel implements MovementModel, EventHandler, Future
long currentTime = Time.getCurrentTime() / timestepConversion; long currentTime = Time.getCurrentTime() / timestepConversion;
while (_controller.getStep() - _controller.getStart() < currentTime) { while (_controller.getStep() - _controller.getStart() < currentTime) {
_controller.nextStep(); if (!_controller.nextStep()) {
return;
}
} }
List<String> allVehicles = _controller.getAllVehicles(); List<String> allVehicles = _controller.getAllVehicles();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment