From 007f9bc5e17554a689b46b5e5bc7dfbf18f94659 Mon Sep 17 00:00:00 2001 From: Kli Kli Date: Mon, 2 Dec 2024 09:47:26 +0100 Subject: [PATCH] feat: use "entry read" unlocks instead of "advancement" unlocks until modonomicon offers better usability for advancement unlocks --- .../pentacles/contact_eldritch_spirit.json | 12 +- .../pentacles/contact_wild_spirit.json | 12 +- .../entries/pentacles/craft_afrit.json | 4 +- .../entries/pentacles/craft_djinni.json | 8 +- .../entries/pentacles/craft_foliot.json | 4 +- .../entries/pentacles/craft_marid.json | 4 +- .../entries/pentacles/possess_afrit.json | 4 +- .../entries/pentacles/possess_djinni.json | 8 +- .../entries/pentacles/possess_foliot.json | 4 +- .../entries/pentacles/possess_marid.json | 4 +- .../pentacles/possess_unbound_afrit.json | 8 +- .../entries/pentacles/summon_afrit.json | 4 +- .../entries/pentacles/summon_djinni.json | 8 +- .../entries/pentacles/summon_foliot.json | 4 +- .../entries/pentacles/summon_marid.json | 4 +- .../pentacles/summon_unbound_afrit.json | 8 +- .../pentacles/summon_unbound_marid.json | 4 +- .../datagen/book/PentaclesCategory.java | 131 +++++++++++++----- 18 files changed, 150 insertions(+), 85 deletions(-) diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_eldritch_spirit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_eldritch_spirit.json index 49a34acaa..102f97b96 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_eldritch_spirit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_eldritch_spirit.json @@ -6,16 +6,16 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/magenta" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/magenta_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/brown" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/brown_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/cyan" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/cyan_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_wild_spirit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_wild_spirit.json index 41f917c90..65d950dd3 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_wild_spirit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/contact_wild_spirit.json @@ -6,16 +6,16 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/pink" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/pink_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/green" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/green_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/light_blue" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/light_blue_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_afrit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_afrit.json index 4f1bee977..7c2d05630 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_afrit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_afrit.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/red" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/red_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.craft_afrit.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_djinni.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_djinni.json index 97d8097c6..4fc1a136f 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_djinni.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_djinni.json @@ -6,12 +6,12 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/light_gray" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/light_gray_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/lime" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/lime_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_foliot.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_foliot.json index 78317af8b..e250d8cb1 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_foliot.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_foliot.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/purple" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/purple_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.craft_foliot.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_marid.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_marid.json index 8fa4327d3..c015c70e9 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_marid.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/craft_marid.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/blue" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/blue_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.craft_marid.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_afrit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_afrit.json index 248d6ef8c..1cead69f5 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_afrit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_afrit.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/red" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/red_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.possess_afrit.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_djinni.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_djinni.json index 36a4aa3a1..db1317c1e 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_djinni.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_djinni.json @@ -6,12 +6,12 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/light_gray" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/light_gray_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/lime" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/lime_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_foliot.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_foliot.json index 03cad44bf..b031381aa 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_foliot.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_foliot.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/yellow" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/yellow_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.possess_foliot.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_marid.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_marid.json index e53ebbde3..4c9655951 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_marid.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_marid.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/blue" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/blue_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.possess_marid.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_unbound_afrit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_unbound_afrit.json index 317d741d1..d63d7775b 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_unbound_afrit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/possess_unbound_afrit.json @@ -6,12 +6,12 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/gray" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/gray_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/orange" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/orange_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_afrit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_afrit.json index 608ae11e1..4b4205d42 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_afrit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_afrit.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/red" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/red_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.summon_afrit.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_djinni.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_djinni.json index fe5b151b6..ed339d67e 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_djinni.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_djinni.json @@ -6,12 +6,12 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/light_gray" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/light_gray_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/lime" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/lime_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_foliot.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_foliot.json index 91ba19865..2479a58f3 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_foliot.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_foliot.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/white" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/white_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.summon_foliot.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_marid.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_marid.json index 7b325dc9a..a337dc7c2 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_marid.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_marid.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/blue" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/blue_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.summon_marid.description", "hide_while_locked": false, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_afrit.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_afrit.json index e5541e41c..a9a443214 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_afrit.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_afrit.json @@ -6,12 +6,12 @@ "type": "modonomicon:and", "children": [ { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/gray" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/gray_chalk" }, { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/orange" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/orange_chalk" } ] }, diff --git a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_marid.json b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_marid.json index 36d0fd1a4..15d4532d1 100644 --- a/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_marid.json +++ b/src/generated/resources/data/occultism/modonomicon/books/dictionary_of_spirits/entries/pentacles/summon_unbound_marid.json @@ -3,8 +3,8 @@ "background_v_index": 0, "category": "pentacles", "condition": { - "type": "modonomicon:advancement", - "advancement_id": "occultism:chalks/black" + "type": "modonomicon:entry_read", + "entry_id": "pentacles/black_chalk" }, "description": "book.occultism.dictionary_of_spirits.pentacles.summon_unbound_marid.description", "hide_while_locked": false, diff --git a/src/main/java/com/klikli_dev/occultism/datagen/book/PentaclesCategory.java b/src/main/java/com/klikli_dev/occultism/datagen/book/PentaclesCategory.java index f2d4dc5e4..c3fcaafca 100644 --- a/src/main/java/com/klikli_dev/occultism/datagen/book/PentaclesCategory.java +++ b/src/main/java/com/klikli_dev/occultism/datagen/book/PentaclesCategory.java @@ -64,7 +64,9 @@ protected void generateEntries(){ var summonFoliot = this.add(new SummonFoliotEntry(this).generate('a')); summonFoliot.withParent(BookEntryParentModel.create(didacticsEntry.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/white")); + .withCondition(BookEntryReadConditionModel.create().withEntry(whiteChalkEntry.getId())); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/white")); var lightGrayChalkEntry = this.add(new LightGrayChalkEntry(this).generate('S')); lightGrayChalkEntry.withParent(BookEntryParentModel.create(whiteChalkEntry.getId())) @@ -79,7 +81,9 @@ protected void generateEntries(){ var possessFoliot = this.add(new PossessFoliotEntry(this).generate('f')); possessFoliot.withParent(BookEntryParentModel.create(yellowChalkEntry.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/yellow")); + .withCondition(BookEntryReadConditionModel.create().withEntry(yellowChalkEntry.getId())); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/yellow")); var purpleChalkEntry = this.add(new PurpleChalkEntry(this).generate('X')); purpleChalkEntry.withParent(BookEntryParentModel.create(yellowChalkEntry.getId())) @@ -87,7 +91,9 @@ protected void generateEntries(){ var craftFoliot = this.add(new CraftFoliotEntry(this).generate('l')); craftFoliot.withParent(BookEntryParentModel.create(purpleChalkEntry.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/purple")); + .withCondition(BookEntryReadConditionModel.create().withEntry(purpleChalkEntry.getId())); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/purple")); var limeChalkEntry = this.add(new LimeChalkEntry(this).generate('L')); limeChalkEntry.withParent(BookEntryParentModel.create(purpleChalkEntry.getId()).withLineReversed(true)) @@ -104,9 +110,16 @@ protected void generateEntries(){ //Tier Djinni var summonDjinni = this.add(new SummonDjinniEntry(this).generate('b')); summonDjinni.withParent(BookEntryParentModel.create(summonFoliot.getId())) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_gray"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/lime"))); + .withCondition( + this.condition().and( + this.condition().entryRead(lightGrayChalkEntry), + this.condition().entryRead(limeChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them +// BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_gray"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/lime")) +// ); var lightBlueChalkEntry = this.add(new LightBlueChalkEntry(this).generate('A')); lightBlueChalkEntry.withParent(BookEntryParentModel.create(summonDjinni.getId()).withLineEnabled(false)) @@ -114,9 +127,15 @@ protected void generateEntries(){ var possessDjinni = this.add(new PossessDjinniEntry(this).generate('g')); possessDjinni.withParent(BookEntryParentModel.create(possessFoliot.getId())) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_gray"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/lime"))); + .withCondition( + this.condition().and( + this.condition().entryRead(lightGrayChalkEntry), + this.condition().entryRead(limeChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_gray"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/lime"))); var orangeChalkEntry = this.add(new OrangeChalkEntry(this).generate('O')); orangeChalkEntry.withParent(BookEntryParentModel.create(limeChalkEntry.getId())) @@ -124,9 +143,15 @@ protected void generateEntries(){ var craftDjinni = this.add(new CraftDjinniEntry(this).generate('m')); craftDjinni.withParent(BookEntryParentModel.create(craftFoliot.getId())) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_gray"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/lime"))); + .withCondition( + this.condition().and( + this.condition().entryRead(lightGrayChalkEntry), + this.condition().entryRead(limeChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_gray"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/lime"))); var grayChalkEntry = this.add(new GrayChalkEntry(this).generate('G')); grayChalkEntry.withParent(BookEntryParentModel.create(lightGrayChalkEntry.getId())) @@ -135,9 +160,15 @@ protected void generateEntries(){ //Tier Unbound Afrit var summonUnboundAfrit = this.add(new SummonUnboundAfritEntry(this).generate('c')); summonUnboundAfrit.withParent(BookEntryParentModel.create(summonDjinni.getId())) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/gray"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/orange"))); + .withCondition( + this.condition().and( + this.condition().entryRead(grayChalkEntry), + this.condition().entryRead(orangeChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/gray"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/orange"))); var redChalkEntry = this.add(new RedChalkEntry(this).generate('R')); redChalkEntry.withParent(BookEntryParentModel.create(orangeChalkEntry.getId())) @@ -145,9 +176,15 @@ protected void generateEntries(){ var possessUnboundAfrit = this.add(new PossessUnboundAfritEntry(this).generate('h')); possessUnboundAfrit.withParent(BookEntryParentModel.create(possessDjinni.getId())) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/gray"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/orange"))); + .withCondition( + this.condition().and( + this.condition().entryRead(grayChalkEntry), + this.condition().entryRead(orangeChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/gray"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/orange"))); var pinkChalkEntry = this.add(new PinkChalkEntry(this).generate('P')); pinkChalkEntry.withParent(BookEntryParentModel.create(possessUnboundAfrit.getId()).withLineEnabled(false)); @@ -158,23 +195,37 @@ protected void generateEntries(){ BookEntryParentModel.create(pinkChalkEntry.getId()).withLineReversed(true), BookEntryParentModel.create(greenChalkEntry.getId()).withLineReversed(true), BookEntryParentModel.create(lightBlueChalkEntry.getId())) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/pink"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/green"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_blue"))); + .withCondition( + this.condition().and( + this.condition().entryRead(pinkChalkEntry), + this.condition().entryRead(greenChalkEntry), + this.condition().entryRead(lightBlueChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them + +// .withCondition(BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/pink"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/green"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/light_blue"))); //Tier Afrit var summonAfrit = this.add(new SummonAfritEntry(this).generate('d')); summonAfrit.withParent(BookEntryParentModel.create(summonUnboundAfrit.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/red")); + .withCondition(this.condition().entryRead(redChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/red")); var possessAfrit = this.add(new PossessAfritEntry(this).generate('i')); possessAfrit.withParent(BookEntryParentModel.create(possessUnboundAfrit.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/red")); + .withCondition(this.condition().entryRead(redChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/red")); var craftAfrit = this.add(new CraftAfritEntry(this).generate('n')); craftAfrit.withParent(BookEntryParentModel.create(craftDjinni.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/red")); + .withCondition(this.condition().entryRead(redChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/red")); var blackChalkEntry = this.add(new BlackChalkEntry(this).generate('K')); blackChalkEntry.withParent(BookEntryParentModel.create(grayChalkEntry.getId())) @@ -183,7 +234,9 @@ protected void generateEntries(){ //Tier Marid var summonUnboundMarid = this.add(new SummonUnboundMaridEntry(this).generate('u')); summonUnboundMarid.withParent(BookEntryParentModel.create(summonAfrit.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/black")); + .withCondition(this.condition().entryRead(blackChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/black")); var blueChalkEntry = this.add(new BlueChalkEntry(this).generate('U')); blueChalkEntry.withParent(BookEntryParentModel.create(redChalkEntry.getId())) @@ -191,21 +244,27 @@ protected void generateEntries(){ var summonMarid = this.add(new SummonMaridEntry(this).generate('e')); summonMarid.withParent(BookEntryParentModel.create(summonUnboundMarid.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/blue")); + .withCondition(this.condition().entryRead(blueChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/blue")); var cyanChalkEntry = this.add(new CyanChalkEntry(this).generate('C')); cyanChalkEntry.withParent(BookEntryParentModel.create(summonMarid.getId()).withLineEnabled(false)); var possessMarid = this.add(new PossessMaridEntry(this).generate('j')); possessMarid.withParent(BookEntryParentModel.create(possessAfrit.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/blue")); + .withCondition(this.condition().entryRead(blueChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/blue")); var brownChalkEntry = this.add(new BrownChalkEntry(this).generate('B')); brownChalkEntry.withParent(BookEntryParentModel.create(possessMarid.getId()).withLineEnabled(false)); var craftMarid = this.add(new CraftMaridEntry(this).generate('o')); craftMarid.withParent(BookEntryParentModel.create(craftAfrit.getId())) - .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/blue")); + .withCondition(this.condition().entryRead(blueChalkEntry)); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/blue")); var magentaChalkEntry = this.add(new MagentaChalkEntry(this).generate('M')); magentaChalkEntry.withParent(BookEntryParentModel.create(craftMarid.getId()).withLineEnabled(false)); @@ -216,9 +275,15 @@ protected void generateEntries(){ BookEntryParentModel.create(magentaChalkEntry.getId()).withLineReversed(true), BookEntryParentModel.create(brownChalkEntry.getId()), BookEntryParentModel.create(cyanChalkEntry.getId()).withLineReversed(true)) - .withCondition(BookAndConditionModel.create().withChildren( - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/magenta"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/brown"), - BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/cyan"))); + .withCondition(this.condition().and( + this.condition().entryRead(magentaChalkEntry), + this.condition().entryRead(brownChalkEntry), + this.condition().entryRead(cyanChalkEntry) + )); + //TODO: enable advancement condition once modonomicon supports skipping them +// .withCondition(BookAndConditionModel.create().withChildren( +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/magenta"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/brown"), +// BookAdvancementConditionModel.create().withAdvancementId("occultism:chalks/cyan"))); } }