mirror of
https://github.com/GTNewHorizons/CraftTweaker.git
synced 2026-11-21 12:32:29 +00:00
Set version Number to 3.1.0
This commit is contained in:
4 files changed
+10
-18
No files matched your search
@@ -70,12 +70,7 @@ public class MineTweakerAPI {
|
||||
};
|
||||
|
||||
static {
|
||||
// List<Class> apiClasses = new ArrayList<Class>();
|
||||
// ClassRegistry.getClasses(apiClasses);
|
||||
//
|
||||
// for (Class cls : apiClasses) {
|
||||
// registerClass(cls);
|
||||
// }
|
||||
registerClassRegistry(ClassRegistry.class, "MT-API");
|
||||
|
||||
registerGlobalSymbol("logger", getJavaStaticGetterSymbol(MineTweakerAPI.class, "getLogger"));
|
||||
registerGlobalSymbol("recipes", getJavaStaticFieldSymbol(MineTweakerAPI.class, "recipes"));
|
||||
@@ -260,7 +255,7 @@ public class MineTweakerAPI {
|
||||
try {
|
||||
Method method = registryClass.getMethod("getClasses", List.class);
|
||||
if ((method.getModifiers() & Modifier.STATIC) == 0) {
|
||||
System.out.println("ERROR: getClasses method in " + registryClass.getName() + " isn't static");
|
||||
logError("ERROR: getClasses method in " + registryClass.getName() + " isn't static");
|
||||
} else {
|
||||
List<Class> classes = new ArrayList<Class>();
|
||||
method.invoke(null, classes);
|
||||
@@ -285,16 +280,12 @@ public class MineTweakerAPI {
|
||||
}
|
||||
|
||||
if (description != null)
|
||||
System.out.println("Loaded class registry: " + description);
|
||||
logInfo("Loaded class registry: " + description);
|
||||
}
|
||||
} catch (NoSuchMethodException ex) {
|
||||
|
||||
} catch (IllegalAccessException ex) {
|
||||
|
||||
} catch (InvocationTargetException ex) {
|
||||
|
||||
} catch (NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
|
||||
logError("Error registering class registry", ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers a class registry. Will attempt to resolve the given class name.
|
||||
|
||||
@@ -66,7 +66,8 @@ public class GlobalRegistry {
|
||||
}
|
||||
}
|
||||
} catch (Throwable ex) {
|
||||
ex.printStackTrace();
|
||||
errors.error("Error while applying expansion", ex);
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user