From b95ecb93b0a447bbcaa2375b436d4c265ea485bb Mon Sep 17 00:00:00 2001 From: yoyosource Date: Fri, 26 Mar 2021 22:11:31 +0100 Subject: [PATCH] Add replace multi space to single --- .../src/de/steamwar/bausystem/world/ScriptListener.java | 1 + 1 file changed, 1 insertion(+) diff --git a/BauSystem_Main/src/de/steamwar/bausystem/world/ScriptListener.java b/BauSystem_Main/src/de/steamwar/bausystem/world/ScriptListener.java index 1f229dc..4a87884 100644 --- a/BauSystem_Main/src/de/steamwar/bausystem/world/ScriptListener.java +++ b/BauSystem_Main/src/de/steamwar/bausystem/world/ScriptListener.java @@ -114,6 +114,7 @@ public class ScriptListener implements Listener { for (String page : bookMeta.getPages()) { for (String command : page.split("\n")) { + command = command.replaceAll(" +", " "); if (command.startsWith("#") || command.trim().isEmpty()) continue; if (command.startsWith(".")) { jumpPoints.put(command.substring(1), commands.size());