From 120fe619809ccefa0144fe04a5046f7c006e9a79 Mon Sep 17 00:00:00 2001 From: Cardillan <122014763+cardillan@users.noreply.github.com> Date: Wed, 14 Jan 2026 19:33:58 +0100 Subject: [PATCH] Zero wait yields (#11561) * Zero wait yields * Zero wait yields (fix) --- core/src/mindustry/logic/LExecutor.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/src/mindustry/logic/LExecutor.java b/core/src/mindustry/logic/LExecutor.java index 83881dd00a..7dd2801b33 100644 --- a/core/src/mindustry/logic/LExecutor.java +++ b/core/src/mindustry/logic/LExecutor.java @@ -1167,7 +1167,12 @@ public class LExecutor{ @Override public void run(LExecutor exec){ - if(curTime >= value.num()){ + if(value.num() <= 0){ + // Just yield without executing the wait again + exec.yield = true; + // Start the next wait afresh ('value' might have been modified remotely by a different processor) + curTime = 0f; + }else if(curTime >= value.num()){ curTime = 0f; }else{ //skip back to self.