From 125f92a4315e0773b2da9403fc2aac8268b7e9e6 Mon Sep 17 00:00:00 2001 From: Cedric Date: Mon, 21 Oct 2024 01:25:43 +0200 Subject: [PATCH] maby fix: signals updateing when the should not --- .../com/troblecodings/signals/signalbox/SignalBoxPathway.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/troblecodings/signals/signalbox/SignalBoxPathway.java b/src/main/java/com/troblecodings/signals/signalbox/SignalBoxPathway.java index 776ae07de..f0e04bbf7 100644 --- a/src/main/java/com/troblecodings/signals/signalbox/SignalBoxPathway.java +++ b/src/main/java/com/troblecodings/signals/signalbox/SignalBoxPathway.java @@ -432,7 +432,6 @@ public void resetPathway(final @Nullable Point point) { this.setPathStatus(EnumPathUsage.FREE, point); resetFirstSignal(); if (data.totalPathwayReset(point)) { - this.isBlocked = false; resetOther(); resetAllTrainNumbers(); sendTrainNumberUpdates(); @@ -442,6 +441,7 @@ public void resetPathway(final @Nullable Point point) { next.updatePreSignals(); next.updateSignalStates(); } + this.isBlocked = false; } } @@ -562,12 +562,12 @@ private boolean isPowerd(final BlockPos pos) { public boolean tryBlock(final BlockPos position) { if (!data.tryBlock(position)) return false; + isBlocked = true; resetFirstSignal(); this.setPathStatus(EnumPathUsage.BLOCKED); if (!isBlocked) { getTrainNumberFromPrevious(); } - isBlocked = true; return true; }