This commit is contained in:
Anuken
2021-06-10 18:51:49 -04:00
parent 35be671d86
commit 9e8e0709b5
27 changed files with 131 additions and 109 deletions
@@ -707,6 +707,11 @@ public class ContentParser{
node.objectives.addAll(parser.readValue(Objective[].class, research.get("objectives")));
}
//all items have a produce requirement unless already specified
if(object instanceof Item i && !node.objectives.contains(o -> o instanceof Produce p && p.content == i)){
node.objectives.add(new Produce(i));
}
//remove old node from parent
if(node.parent != null){
node.parent.children.remove(node);