aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/me/Danker/DankersSkyblockMod.java31
1 files changed, 29 insertions, 2 deletions
diff --git a/src/main/java/me/Danker/DankersSkyblockMod.java b/src/main/java/me/Danker/DankersSkyblockMod.java
index 87fdd23..a1b9b2a 100644
--- a/src/main/java/me/Danker/DankersSkyblockMod.java
+++ b/src/main/java/me/Danker/DankersSkyblockMod.java
@@ -7,7 +7,6 @@ import me.Danker.handlers.*;
import me.Danker.utils.TicTacToeUtils;
import me.Danker.utils.Utils;
import net.minecraft.block.Block;
-import net.minecraft.block.state.BlockState;
import net.minecraft.block.state.IBlockState;
import net.minecraft.client.Minecraft;
import net.minecraft.client.entity.EntityPlayerSP;
@@ -101,6 +100,7 @@ public class DankersSkyblockMod
static double lastMaddoxTime = 0;
static KeyBinding[] keyBindings = new KeyBinding[2];
static boolean usingLabymod = false;
+ static boolean usingSpiderFrogOldAnimationsMod = false;
public static String guiToOpen = null;
static boolean foundLivid = false;
static Entity livid = null;
@@ -310,6 +310,13 @@ public class DankersSkyblockMod
public void postInit(final FMLPostInitializationEvent event) {
usingLabymod = Loader.isModLoaded("labymod");
System.out.println("LabyMod detection: " + usingLabymod);
+ try {
+ Class clazz = Class.forName("com.spiderfrog.oldanimations.OldAnimationsMod");
+ usingSpiderFrogOldAnimationsMod = true;
+ } catch (Exception var1) {
+ usingSpiderFrogOldAnimationsMod = false;
+ }
+ System.out.println("OldAnimationsMod detection: " + usingSpiderFrogOldAnimationsMod);
}
// Update checker
@@ -317,7 +324,27 @@ public class DankersSkyblockMod
public void onJoin(EntityJoinWorldEvent event) {
if (!updateChecked) {
updateChecked = true;
-
+
+ if (usingSpiderFrogOldAnimationsMod) {
+ new Thread(()->{
+ while (true) {
+ if (Minecraft.getMinecraft().thePlayer == null) {
+ try {
+ Thread.sleep(500);
+ } catch (InterruptedException e) {
+ e.printStackTrace();
+ }
+ } else {
+ Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(EnumChatFormatting.RED +
+ "You are using spiderfrog's OldAnimationsMod.\n" +
+ "Danker's Skyblock Mod is incompatible with OldAnimationsMod.\n" +
+ "Please remove OldAnimationsMod or you may experience crashes or other issues."));
+ break;
+ }
+ }
+ }).start();
+ }
+
// MULTI THREAD DRIFTING
new Thread(() -> {
EntityPlayer player = Minecraft.getMinecraft().thePlayer;