diff --git a/Minepacks/src/at/pcgamingfreaks/Minepacks/Bukkit/MinepacksBadRabbit.java b/Minepacks/src/at/pcgamingfreaks/Minepacks/Bukkit/MinepacksBadRabbit.java
index 9917e79..6cdabab 100644
--- a/Minepacks/src/at/pcgamingfreaks/Minepacks/Bukkit/MinepacksBadRabbit.java
+++ b/Minepacks/src/at/pcgamingfreaks/Minepacks/Bukkit/MinepacksBadRabbit.java
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2020 GeorgH93
+ * Copyright (C) 2022 GeorgH93
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -36,6 +36,7 @@ public class MinepacksBadRabbit extends BadRabbit
{
JavaPlugin newPluginInstance = null;
Plugin pcgfPluginLib = Bukkit.getPluginManager().getPlugin("PCGF_PluginLib");
+ boolean standalone = true;
if(pcgfPluginLib != null)
{
if(new Version(pcgfPluginLib.getDescription().getVersion()).olderThan(new Version(MagicValues.MIN_PCGF_PLUGIN_LIB_VERSION)))
@@ -45,18 +46,22 @@ public class MinepacksBadRabbit extends BadRabbit
else
{
getLogger().info("PCGF-PluginLib installed. Switching to normal mode!");
- newPluginInstance = new Minepacks();
+ standalone = false;
}
}
else
{
getLogger().info("PCGF-PluginLib not installed. Switching to standalone mode!");
}
- if(newPluginInstance == null)
+ if(standalone)
{
Class> standaloneClass = Class.forName("at.pcgamingfreaks.MinepacksStandalone.Bukkit.Minepacks");
- newPluginInstance = (JavaPlugin) standaloneClass.newInstance();
+ return (JavaPlugin) standaloneClass.newInstance();
+ }
+ else
+ {
+ Class> normalClass = Class.forName("at.pcgamingfreaks.Minepacks.Bukkit.Minepacks");
+ return (JavaPlugin) normalClass.newInstance();
}
- return newPluginInstance;
}
}
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 7b3ad90..a189581 100644
--- a/pom.xml
+++ b/pom.xml
@@ -7,7 +7,7 @@
pom
- 2.4.5
+ 2.4.5.1
UTF-8
UTF-8