This commit is contained in:
Anuken
2020-10-09 19:10:16 -04:00
parent 5455ef4361
commit 5a31d419fc
2 changed files with 54 additions and 53 deletions
+2 -2
View File
@@ -110,8 +110,8 @@ android{
} }
if(project.hasProperty("RELEASE_STORE_FILE") || System.getenv("CI") == "true"){ if(project.hasProperty("RELEASE_STORE_FILE") || System.getenv("CI") == "true"){
buildTypes { buildTypes{
release { release{
signingConfig signingConfigs.release signingConfig signingConfigs.release
} }
} }
+6 -5
View File
@@ -33,6 +33,7 @@ import mindustry.world.draw.*;
import mindustry.world.meta.*; import mindustry.world.meta.*;
import java.lang.reflect.*; import java.lang.reflect.*;
import java.util.*;
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
public class ContentParser{ public class ContentParser{
@@ -554,10 +555,13 @@ public class ContentParser{
private void readFields(Object object, JsonValue jsonMap, boolean stripType){ private void readFields(Object object, JsonValue jsonMap, boolean stripType){
if(stripType) jsonMap.remove("type"); if(stripType) jsonMap.remove("type");
if(object instanceof UnlockableContent unlock){
JsonValue research = jsonMap.remove("research"); JsonValue research = jsonMap.remove("research");
readFields(object, jsonMap);
if(object instanceof UnlockableContent unlock && research != null){
//add research tech node //add research tech node
if(research != null){
String researchName; String researchName;
ItemStack[] customRequirements; ItemStack[] customRequirements;
@@ -603,11 +607,8 @@ public class ContentParser{
//reparent the node //reparent the node
node.parent = parent; node.parent = parent;
}); });
} }
} }
readFields(object, jsonMap);
}
void readFields(Object object, JsonValue jsonMap){ void readFields(Object object, JsonValue jsonMap){
toBeParsed.remove(object); toBeParsed.remove(object);