From ca338699faee167e78b94b249f641d1d3a6d0784 Mon Sep 17 00:00:00 2001 From: yoyosource Date: Tue, 14 Mar 2023 18:23:52 +0100 Subject: [PATCH] Hotfix If Signed-off-by: yoyosource --- .../src/de/steamwar/bausystem/features/script/command/If.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/BauSystem_Main/src/de/steamwar/bausystem/features/script/command/If.java b/BauSystem_Main/src/de/steamwar/bausystem/features/script/command/If.java index e2a2ac44..47d92f25 100644 --- a/BauSystem_Main/src/de/steamwar/bausystem/features/script/command/If.java +++ b/BauSystem_Main/src/de/steamwar/bausystem/features/script/command/If.java @@ -46,7 +46,7 @@ public class If implements SpecialCommand { BauSystem.MESSAGE.send("SCRIPT_COMMAND_ERROR_NO_BOOLEAN", scriptExecutor.getPlayer()); return false; } - if (v.asBoolean()) { + if (v.asBoolean() && command.length > 2) { jumpToIndex(scriptExecutor, command[2]); } else if (command.length > 3) { jumpToIndex(scriptExecutor, command[3]);