mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-04-14 03:36:03 +00:00
Version Check?
This commit is contained in:
@@ -24,7 +24,7 @@ plugins {
|
|||||||
id "de.undercouch.download" version "5.0.1"
|
id "de.undercouch.download" version "5.0.1"
|
||||||
}
|
}
|
||||||
|
|
||||||
version '2.3.11-1.19.3' // Needs to be version specific
|
version '2.3.12-1.19.3' // Needs to be version specific
|
||||||
def nmsVersion = "1.19.3" //[NMS]
|
def nmsVersion = "1.19.3" //[NMS]
|
||||||
def apiVersion = '1.19'
|
def apiVersion = '1.19'
|
||||||
def specialSourceVersion = '1.11.0' //[NMS]
|
def specialSourceVersion = '1.11.0' //[NMS]
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ import com.volmit.iris.core.link.MultiverseCoreLink;
|
|||||||
import com.volmit.iris.core.link.MythicMobsLink;
|
import com.volmit.iris.core.link.MythicMobsLink;
|
||||||
import com.volmit.iris.core.loader.IrisData;
|
import com.volmit.iris.core.loader.IrisData;
|
||||||
import com.volmit.iris.core.nms.INMS;
|
import com.volmit.iris.core.nms.INMS;
|
||||||
|
import com.volmit.iris.core.nms.v19_3.NMSBinding19_3;
|
||||||
import com.volmit.iris.core.pregenerator.LazyPregenerator;
|
import com.volmit.iris.core.pregenerator.LazyPregenerator;
|
||||||
import com.volmit.iris.core.service.StudioSVC;
|
import com.volmit.iris.core.service.StudioSVC;
|
||||||
import com.volmit.iris.core.tools.IrisToolbelt;
|
import com.volmit.iris.core.tools.IrisToolbelt;
|
||||||
@@ -532,6 +533,7 @@ public class Iris extends VolmitPlugin implements Listener {
|
|||||||
enable();
|
enable();
|
||||||
super.onEnable();
|
super.onEnable();
|
||||||
Bukkit.getPluginManager().registerEvents(this, this);
|
Bukkit.getPluginManager().registerEvents(this, this);
|
||||||
|
setupChecks();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onDisable() {
|
public void onDisable() {
|
||||||
@@ -565,6 +567,13 @@ public class Iris extends VolmitPlugin implements Listener {
|
|||||||
return C.BOLD + "" + C.DARK_GRAY + "[" + C.BOLD + "" + C.IRIS + "Iris" + C.BOLD + C.DARK_GRAY + "]" + C.RESET + "" + C.GRAY + ": ";
|
return C.BOLD + "" + C.DARK_GRAY + "[" + C.BOLD + "" + C.IRIS + "Iris" + C.BOLD + C.DARK_GRAY + "]" + C.RESET + "" + C.GRAY + ": ";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void setupChecks() {
|
||||||
|
if (!instance.getDescription().getVersion().contains(NMSBinding19_3.NMS_VERSION)) {
|
||||||
|
Iris.warn("============================================");
|
||||||
|
Iris.warn("Iris is not compatible with this version of Minecraft.\nPlease use " + NMSBinding19_3.NMS_VERSION + " or use an older version of Iris.");
|
||||||
|
Iris.warn("============================================");
|
||||||
|
}
|
||||||
|
}
|
||||||
private void checkConfigHotload() {
|
private void checkConfigHotload() {
|
||||||
if (configWatcher.checkModified()) {
|
if (configWatcher.checkModified()) {
|
||||||
IrisSettings.invalidate();
|
IrisSettings.invalidate();
|
||||||
|
|||||||
@@ -74,6 +74,7 @@ public class NMSBinding19_3 implements INMSBinding {
|
|||||||
private final AtomicCache<RegistryAccess> registryAccess = new AtomicCache<>();
|
private final AtomicCache<RegistryAccess> registryAccess = new AtomicCache<>();
|
||||||
private final AtomicCache<Method> byIdRef = new AtomicCache<>();
|
private final AtomicCache<Method> byIdRef = new AtomicCache<>();
|
||||||
private Field biomeStorageCache = null;
|
private Field biomeStorageCache = null;
|
||||||
|
public static final String NMS_VERSION = "1.19.3";
|
||||||
|
|
||||||
private static Object getFor(Class<?> type, Object source) {
|
private static Object getFor(Class<?> type, Object source) {
|
||||||
Object o = fieldFor(type, source);
|
Object o = fieldFor(type, source);
|
||||||
|
|||||||
Reference in New Issue
Block a user