mirror of
https://github.com/GeorgH93/Minepacks.git
synced 2024-11-14 10:45:23 +01:00
Check PluginLib version before checking MC version
This commit is contained in:
parent
6151b08944
commit
c53cdfdaf5
@ -85,6 +85,14 @@ public static Minepacks getInstance()
|
||||
public void onEnable()
|
||||
{
|
||||
Utils.warnOnJava_1_7(getLogger());
|
||||
|
||||
if(PluginLib.getInstance().getVersion().olderThan(new Version("1.0.8-SNAPSHOT")))
|
||||
{
|
||||
getLogger().warning("You are using an outdated version of the PCGF PluginLib! Please update it!");
|
||||
setEnabled(false);
|
||||
return;
|
||||
}
|
||||
|
||||
//region Check compatibility with used minecraft version
|
||||
if(MCVersion.is(MCVersion.UNKNOWN) || MCVersion.isNewerThan(MCVersion.MC_NMS_1_14_R1))
|
||||
{
|
||||
@ -96,13 +104,6 @@ public void onEnable()
|
||||
}
|
||||
//endregion
|
||||
|
||||
if(PluginLib.getInstance().getVersion().olderThan(new Version("1.0.8-SNAPSHOT")))
|
||||
{
|
||||
getLogger().warning("You are using an outdated version of the PCGF PluginLib! Please update it!");
|
||||
setEnabled(false);
|
||||
return;
|
||||
}
|
||||
|
||||
//region check if a plugin folder exists (was renamed from MinePacks to Minepacks with the V2.0 update)
|
||||
if(!getDataFolder().exists())
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user