From e5799127330589d5e9793047d60552b37f417595 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Thu, 8 Aug 2024 12:28:35 -0400 Subject: [PATCH] Debugging --- src/engine/ConfigParsing/EffectsParser.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/engine/ConfigParsing/EffectsParser.java b/src/engine/ConfigParsing/EffectsParser.java index 6b489d39..eb2b4dd6 100644 --- a/src/engine/ConfigParsing/EffectsParser.java +++ b/src/engine/ConfigParsing/EffectsParser.java @@ -10,6 +10,7 @@ package engine.ConfigParsing; import engine.ConfigParsing.EffectEntry.EffectEntry; import engine.gameManager.ConfigManager; +import org.pmw.tinylog.Logger; import java.io.IOException; import java.nio.file.Files; @@ -53,7 +54,14 @@ public class EffectsParser { // Parse effect entry description - String firstLine = effectData.substring(0, effectData.indexOf('\n')); + String firstLine; + + try { + firstLine = effectData.substring(0, effectData.indexOf('\n')); + } catch (Exception e) { + Logger.error(e); + } + ArrayList effectDescription = new ArrayList<>(); Matcher matcher = STRSPLIT_REGEX.matcher(firstLine);