aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/makamys
diff options
context:
space:
mode:
authormakamys <makamys@outlook.com>2023-02-09 22:41:01 +0100
committermakamys <makamys@outlook.com>2023-02-09 22:41:32 +0100
commit783b4575d37d86c69b0d2c8690fd13da576f1000 (patch)
tree812b95d0df67dd2a9c2aa57b8a6ce998bc5c32f5 /src/main/java/makamys
parentcd5305c6a383ebb8bf530d0f909c2d32c2ab6723 (diff)
downloadNeodymium-783b4575d37d86c69b0d2c8690fd13da576f1000.tar.gz
Neodymium-783b4575d37d86c69b0d2c8690fd13da576f1000.tar.bz2
Neodymium-783b4575d37d86c69b0d2c8690fd13da576f1000.zip
Move constants to Constants class
Fixes crash with something (AppleCore? WitchingGadgets? Hodgepodge?)
Diffstat (limited to 'src/main/java/makamys')
-rw-r--r--src/main/java/makamys/neodymium/Compat.java2
-rw-r--r--src/main/java/makamys/neodymium/Constants.java1
-rw-r--r--src/main/java/makamys/neodymium/Neodymium.java10
-rw-r--r--src/main/java/makamys/neodymium/config/Config.java7
-rw-r--r--src/main/java/makamys/neodymium/config/NdGuiConfig.java2
-rw-r--r--src/main/java/makamys/neodymium/util/ChatUtil.java4
6 files changed, 14 insertions, 12 deletions
diff --git a/src/main/java/makamys/neodymium/Compat.java b/src/main/java/makamys/neodymium/Compat.java
index 35eac6b..95c6ff4 100644
--- a/src/main/java/makamys/neodymium/Compat.java
+++ b/src/main/java/makamys/neodymium/Compat.java
@@ -1,6 +1,6 @@
package makamys.neodymium;
-import static makamys.neodymium.Neodymium.LOGGER;
+import static makamys.neodymium.Constants.LOGGER;
import java.io.ByteArrayInputStream;
import java.io.InputStream;
diff --git a/src/main/java/makamys/neodymium/Constants.java b/src/main/java/makamys/neodymium/Constants.java
index f8eb12b..47ea8c6 100644
--- a/src/main/java/makamys/neodymium/Constants.java
+++ b/src/main/java/makamys/neodymium/Constants.java
@@ -6,6 +6,7 @@ import org.apache.logging.log4j.Logger;
public class Constants {
public static final String MODID = "neodymium";
+ public static final String VERSION = "@VERSION@";
public static final Logger LOGGER = LogManager.getLogger(MODID);
public static final String PROTOCOL = "neodymiumvirtualjar";
diff --git a/src/main/java/makamys/neodymium/Neodymium.java b/src/main/java/makamys/neodymium/Neodymium.java
index 48c79f4..615d67e 100644
--- a/src/main/java/makamys/neodymium/Neodymium.java
+++ b/src/main/java/makamys/neodymium/Neodymium.java
@@ -1,5 +1,9 @@
package makamys.neodymium;
+import static makamys.neodymium.Constants.LOGGER;
+import static makamys.neodymium.Constants.MODID;
+import static makamys.neodymium.Constants.VERSION;
+
import java.util.ArrayList;
import java.util.List;
@@ -32,13 +36,9 @@ import net.minecraftforge.client.event.RenderGameOverlayEvent;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.event.world.WorldEvent;
-@Mod(modid = Neodymium.MODID, version = Neodymium.VERSION, guiFactory = "makamys.neodymium.config.GuiFactory")
+@Mod(modid = MODID, version = VERSION, guiFactory = "makamys.neodymium.config.GuiFactory")
public class Neodymium
{
- public static final String MODID = "neodymium";
- public static final String VERSION = "@VERSION@";
-
- public static final Logger LOGGER = LogManager.getLogger(MODID);
private static final Config.ReloadInfo CONFIG_RELOAD_INFO = new Config.ReloadInfo();
diff --git a/src/main/java/makamys/neodymium/config/Config.java b/src/main/java/makamys/neodymium/config/Config.java
index 8dc7ffa..4935851 100644
--- a/src/main/java/makamys/neodymium/config/Config.java
+++ b/src/main/java/makamys/neodymium/config/Config.java
@@ -4,8 +4,9 @@ import static java.nio.file.StandardWatchEventKinds.ENTRY_CREATE;
import static java.nio.file.StandardWatchEventKinds.ENTRY_DELETE;
import static java.nio.file.StandardWatchEventKinds.ENTRY_MODIFY;
-import static makamys.neodymium.Neodymium.LOGGER;
-import static makamys.neodymium.Neodymium.MODID;
+import static makamys.neodymium.Constants.LOGGER;
+import static makamys.neodymium.Constants.MODID;
+import static makamys.neodymium.Constants.VERSION;
import java.io.File;
import java.io.IOException;
@@ -100,7 +101,7 @@ public class Config {
e.printStackTrace();
}
- config = new Configuration(configFile, Neodymium.VERSION);
+ config = new Configuration(configFile, VERSION);
config.load();
diff --git a/src/main/java/makamys/neodymium/config/NdGuiConfig.java b/src/main/java/makamys/neodymium/config/NdGuiConfig.java
index ff16595..6be497d 100644
--- a/src/main/java/makamys/neodymium/config/NdGuiConfig.java
+++ b/src/main/java/makamys/neodymium/config/NdGuiConfig.java
@@ -1,6 +1,6 @@
package makamys.neodymium.config;
-import static makamys.neodymium.Neodymium.MODID;
+import static makamys.neodymium.Constants.MODID;
import cpw.mods.fml.client.config.GuiConfig;
import net.minecraft.client.gui.GuiScreen;
diff --git a/src/main/java/makamys/neodymium/util/ChatUtil.java b/src/main/java/makamys/neodymium/util/ChatUtil.java
index 05b31cf..7c2337f 100644
--- a/src/main/java/makamys/neodymium/util/ChatUtil.java
+++ b/src/main/java/makamys/neodymium/util/ChatUtil.java
@@ -1,7 +1,7 @@
package makamys.neodymium.util;
-import static makamys.neodymium.Neodymium.LOGGER;
-import static makamys.neodymium.Neodymium.MODID;
+import static makamys.neodymium.Constants.LOGGER;
+import static makamys.neodymium.Constants.MODID;
import java.util.HashSet;
import java.util.Set;