Add params for the exception message

Signed-off-by: cpw <[email protected]>

tweak logging

Signed-off-by: cpw <[email protected]>
This commit is contained in:
cpw committed 2019-06-15 19:47:08 -04:00
1 parent e1cdb2e558
commit 37a896fe1b
2 files changed
+3 -1

No files matched your search

@@ -25,6 +25,7 @@ import net.minecraftforge.fml.loading.EarlyLoadingException;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
@@ -52,7 +53,7 @@ public class ModLoadingException extends RuntimeException
private final List<Object> context;
public ModLoadingException(final IModInfo modInfo, final ModLoadingStage errorStage, final String i18nMessage, final Throwable originalException, Object... context) {
super("Mod Loading Exception : "+i18nMessage, originalException);
super("Mod Loading Exception : " + i18nMessage + " " + Arrays.toString(Streams.concat(Stream.of(modInfo, errorStage, originalException), Stream.of(context)).toArray()), originalException);
this.modInfo = modInfo;
this.errorStage = errorStage;
this.i18nMessage = i18nMessage;