From d18579b59adcec05120ee8e36199e8fc188c513d Mon Sep 17 00:00:00 2001 From: BalaM314 <71201189+BalaM314@users.noreply.github.com> Date: Thu, 28 Jul 2022 19:11:31 +0530 Subject: [PATCH] Allow `printflush`ing to null (#7243) * Allow `printflush`ing to null * Dumb --- core/src/mindustry/logic/LExecutor.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/src/mindustry/logic/LExecutor.java b/core/src/mindustry/logic/LExecutor.java index 10094be0da..aa6daf4b5a 100644 --- a/core/src/mindustry/logic/LExecutor.java +++ b/core/src/mindustry/logic/LExecutor.java @@ -1020,14 +1020,15 @@ public class LExecutor{ @Override public void run(LExecutor exec){ - + if(exec.building(target) instanceof MessageBuild d && (d.team == exec.team || exec.privileged)){ d.message.setLength(0); d.message.append(exec.textBuffer, 0, Math.min(exec.textBuffer.length(), maxTextBuffer)); - exec.textBuffer.setLength(0); } + exec.textBuffer.setLength(0); + } }