Rule for Serpulo core unloaders taking items from the core

This commit is contained in:
Anuken
2025-12-21 16:01:27 -05:00
parent f64279fb75
commit 861678fd71
6 changed files with 24 additions and 0 deletions

View File

@@ -394,6 +394,13 @@ public class ContentParser{
}
}
@Override
protected Object newInstance(Class type){
Object o = super.newInstance(type);
onNewInstance(o, type);
return o;
}
@Override
public <T> T readValue(Class<T> type, Class elementType, JsonValue jsonData, Class keyType){
T t = internalRead(type, elementType, jsonData, keyType);
@@ -1347,6 +1354,8 @@ public class ContentParser{
Log.warn(string, format);
}
void onNewInstance(Object object, Class<?> type){}
public Json getJson(){
checkInit();
return parser;