Still trying to undestand where is the problem
This commit is contained in:
@@ -51,6 +51,8 @@ public class NMSReflect {
|
||||
isInit = true;
|
||||
}
|
||||
|
||||
Log.info("[NMSReflect] Initializing NMS obfuscation mapping...");
|
||||
|
||||
try {
|
||||
ReflectClass<?> obfHelperClass;
|
||||
try {
|
||||
@@ -115,6 +117,8 @@ public class NMSReflect {
|
||||
|
||||
if (exIfUnableToGetInstanceClass != null)
|
||||
throw exIfUnableToGetInstanceClass;
|
||||
|
||||
Log.info("[NMSReflect] Obfuscation mapping loaded for " + mappings.size() + " classes.");
|
||||
} catch (Throwable t) {
|
||||
Log.severe("[NMSReflect] The plugin will not be able to access NMS stuff because the obfuscation mapping couldn't be loaded.", t);
|
||||
CLASSES_BY_MOJ.clear();
|
||||
|
@@ -424,7 +424,7 @@ public class ReflectRegistry {
|
||||
public static final ReflectField<?> chunks = wrapEx(() -> REFLECT.field("chunks"));
|
||||
|
||||
public static final class Chunks {
|
||||
public static final ReflectClass<?> REFLECT = wrapEx(() -> Reflect.ofClass("io.papermc.paper.configuration.WorldConfiguration.Chunks"));
|
||||
public static final ReflectClass<?> REFLECT = wrapEx(() -> Reflect.ofClass("io.papermc.paper.configuration.WorldConfiguration$Chunks"));
|
||||
public static final ReflectField<?> autoSavePeriod = wrapEx(() -> REFLECT.field("autoSaveInterval"));
|
||||
}
|
||||
}
|
||||
@@ -492,6 +492,9 @@ public class ReflectRegistry {
|
||||
f.get(null);
|
||||
}
|
||||
} catch (Throwable t) {
|
||||
if (t instanceof ExceptionInInitializerError eiie && eiie.getCause() != null) {
|
||||
t = eiie.getCause();
|
||||
}
|
||||
Log.severe("Error while initilizing a ReflectRegistry entry at " + cl.getName(), t);
|
||||
}
|
||||
for (Class<?> declaredClass : cl.getDeclaredClasses()) {
|
||||
|
Reference in New Issue
Block a user