diff --git a/src/main/java/club/joylink/rtss/simulation/cbtc/ATS/service/AtsPlanService.java b/src/main/java/club/joylink/rtss/simulation/cbtc/ATS/service/AtsPlanService.java index 11230c68a..c17f975c7 100644 --- a/src/main/java/club/joylink/rtss/simulation/cbtc/ATS/service/AtsPlanService.java +++ b/src/main/java/club/joylink/rtss/simulation/cbtc/ATS/service/AtsPlanService.java @@ -383,12 +383,12 @@ public class AtsPlanService { if (Objects.equals(train.getPlanStandTrack(), nextStationPlan.getSection().getCode())) { return; } else { - long runningTime = ChronoUnit.SECONDS.between(stationPlan.getLeaveTime(), nextStationPlan.getArriveTime()); + long planTime = ChronoUnit.SECONDS.between(stationPlan.getLeaveTime(), nextStationPlan.getArriveTime()); + long runningTime = planTime; if (estimatedLeaveTime != null) { runningTime = ChronoUnit.SECONDS.between(estimatedLeaveTime, nextStationPlan.getArriveTime()); } - long planTime = ChronoUnit.SECONDS.between(stationPlan.getLeaveTime(), nextStationPlan.getArriveTime()); if (runningTime > planTime * 2) { runningTime = planTime * 2; }