aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/makamys/neodymium
diff options
context:
space:
mode:
authorFalsePattern <30945458+FalsePattern@users.noreply.github.com>2022-06-27 18:16:15 +0200
committerFalsePattern <30945458+FalsePattern@users.noreply.github.com>2022-06-27 18:16:15 +0200
commit5436579d6d88ac17f22de8033667c01466c22b2e (patch)
treed567fadda922d9102848e196f98a72938e45a89f /src/main/java/makamys/neodymium
parent6873c69828d5b00288fadbb49a8c63366e5256a9 (diff)
downloadNeodymium-5436579d6d88ac17f22de8033667c01466c22b2e.tar.gz
Neodymium-5436579d6d88ac17f22de8033667c01466c22b2e.tar.bz2
Neodymium-5436579d6d88ac17f22de8033667c01466c22b2e.zip
Triangulator compatiblity tweak
Diffstat (limited to 'src/main/java/makamys/neodymium')
-rw-r--r--src/main/java/makamys/neodymium/Compat.java17
-rw-r--r--src/main/java/makamys/neodymium/Neodymium.java1
2 files changed, 18 insertions, 0 deletions
diff --git a/src/main/java/makamys/neodymium/Compat.java b/src/main/java/makamys/neodymium/Compat.java
new file mode 100644
index 0000000..7410928
--- /dev/null
+++ b/src/main/java/makamys/neodymium/Compat.java
@@ -0,0 +1,17 @@
+package makamys.neodymium;
+
+import com.falsepattern.triangulator.api.ToggleableTessellator;
+import cpw.mods.fml.common.Loader;
+import net.minecraft.client.renderer.Tessellator;
+
+public class Compat {
+ public static void applyCompatibilityTweaks() {
+ if (Loader.isModLoaded("triangulator")) {
+ disableTriangulator();
+ }
+ }
+
+ private static void disableTriangulator() {
+ ((ToggleableTessellator)Tessellator.instance).disableTriangulator();
+ }
+}
diff --git a/src/main/java/makamys/neodymium/Neodymium.java b/src/main/java/makamys/neodymium/Neodymium.java
index 941a46f..0ec06ce 100644
--- a/src/main/java/makamys/neodymium/Neodymium.java
+++ b/src/main/java/makamys/neodymium/Neodymium.java
@@ -47,6 +47,7 @@ public class Neodymium
@EventHandler
public void preInit(FMLConstructionEvent event) {
MCLib.init();
+ Compat.applyCompatibilityTweaks();
}
@EventHandler