mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-01-07 05:50:54 +07:00
Bugfixes
This commit is contained in:
parent
5455ef4361
commit
5a31d419fc
@ -33,6 +33,7 @@ import mindustry.world.draw.*;
|
||||
import mindustry.world.meta.*;
|
||||
|
||||
import java.lang.reflect.*;
|
||||
import java.util.*;
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public class ContentParser{
|
||||
@ -554,10 +555,13 @@ public class ContentParser{
|
||||
private void readFields(Object object, JsonValue jsonMap, boolean stripType){
|
||||
if(stripType) jsonMap.remove("type");
|
||||
|
||||
if(object instanceof UnlockableContent unlock){
|
||||
JsonValue research = jsonMap.remove("research");
|
||||
|
||||
readFields(object, jsonMap);
|
||||
|
||||
if(object instanceof UnlockableContent unlock && research != null){
|
||||
|
||||
//add research tech node
|
||||
if(research != null){
|
||||
String researchName;
|
||||
ItemStack[] customRequirements;
|
||||
|
||||
@ -603,11 +607,8 @@ public class ContentParser{
|
||||
//reparent the node
|
||||
node.parent = parent;
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
readFields(object, jsonMap);
|
||||
}
|
||||
|
||||
void readFields(Object object, JsonValue jsonMap){
|
||||
toBeParsed.remove(object);
|
||||
|
Loading…
Reference in New Issue
Block a user