From 8d2ad4c0ed09a349476179fad4f4ba9c87eb5b10 Mon Sep 17 00:00:00 2001 From: Standing-Storm <120433252+Standing-Storm@users.noreply.github.com> Date: Tue, 27 Aug 2024 00:20:38 -0500 Subject: [PATCH] [Xedra Evolved] Add the "XEDRA Operative, Department of Extra-Normal Capabilities, SATOR Division" profession (#75718) * Initial commit * change profession name * Add effect * Add more magic squares * Add To Cause Armed Men * Add research system * Add focus handling * More fixes * Remove effect after research is completed * Allow seeing underwater with To Operate Under the Water * Fix spacing, correct components --- data/mods/Xedra_Evolved/effects/effects.json | 46 ++++++ .../eocs/hedge_research_eocs.json | 137 +++++++++++++++ .../Xedra_Evolved/eocs/profession_eocs.json | 10 ++ .../Xedra_Evolved/itemgroups/itemgroups.json | 3 +- .../items/hedge_magic_items.json | 156 ++++++++++++++++++ .../spellbooks_hedge.json | 108 ++++++++++++ .../Xedra_Evolved/monsters/monstergroup.json | 10 ++ .../monsters/summoned_monsters.json | 43 +++++ .../Xedra_Evolved/player/professions.json | 49 ++++++ .../requirements/spell_components.json | 43 +++++ data/mods/Xedra_Evolved/scenario.json | 3 +- .../spells/hedge_magic_eocs.json | 109 +++++++++++- .../spells/hedge_magic_spells.json | 142 +++++++++++++++- 13 files changed, 852 insertions(+), 7 deletions(-) create mode 100644 data/mods/Xedra_Evolved/eocs/hedge_research_eocs.json create mode 100644 data/mods/Xedra_Evolved/eocs/profession_eocs.json create mode 100644 data/mods/Xedra_Evolved/monsters/summoned_monsters.json diff --git a/data/mods/Xedra_Evolved/effects/effects.json b/data/mods/Xedra_Evolved/effects/effects.json index 1b111093afb24..96a37b55c72e2 100644 --- a/data/mods/Xedra_Evolved/effects/effects.json +++ b/data/mods/Xedra_Evolved/effects/effects.json @@ -1693,6 +1693,13 @@ } ] }, + { + "type": "effect_type", + "id": "effect_xe_deciphering_hedge_tome", + "//": "Hidden effect, used to check that you're still researching.", + "name": [ "" ], + "desc": [ "" ] + }, { "type": "effect_type", "id": "effect_hedge_nether_eye_paste", @@ -1779,6 +1786,45 @@ "desc": [ "Hunt. Kill. Feed. Sleep." ], "flags": [ "CANNIBAL", "PRED4", "PSYCHOPATH", "STRICT_HUMANITARIAN" ] }, + { + "type": "effect_type", + "id": "effect_hedge_walk_on_water_magic_square", + "name": [ "Water-Walking" ], + "desc": [ "NAHARIAMA\nA Q\nH E\nA Q\nR\nI\nA Q\nM QA\nA" ], + "//": "The above description replicates a magic square and should not be translated", + "remove_message": "Your water-walking charm has faded.", + "decay_messages": [ [ "Your water-walking charm is about to fade.", "bad" ] ], + "max_duration": "30 m", + "max_intensity": 30, + "int_dur_factor": "1 m", + "flags": [ "ITEM_WATERPROOFING", "WATERWALKING" ] + }, + { + "type": "effect_type", + "id": "effect_hedge_breathe_water_magic_square", + "name": [ "Water-Breathing" ], + "desc": [ "BURNAHEU\nULORIPTE\nROMILAPH\nNRITILIA\nAILITIRN\nHPALIMOR\nETPIROLU\nUEHANRUB" ], + "//": "The above description replicates a magic square and should not be translated", + "remove_message": "Your water-breathing charm has faded.", + "decay_messages": [ [ "Your water-breathing charm is about to fade.", "bad" ] ], + "max_duration": "2 h", + "max_intensity": 120, + "int_dur_factor": "1 m", + "flags": [ "ITEM_WATERPROOFING", "GILLS", "EYE_MEMBRANE" ] + }, + { + "type": "effect_type", + "id": "effect_invisibility_magic_square", + "name": [ "Invisibility" ], + "desc": [ "TALAC\nA A\nL L\nA A\nCALAT" ], + "//": "The above description replicates a magic square and should not be translated", + "remove_message": "Your invisibility charm has faded.", + "decay_messages": [ [ "Your invisibility charm is about to fade.", "bad" ] ], + "max_duration": "77 m", + "max_intensity": 77, + "int_dur_factor": "1 m", + "flags": [ "INVISIBLE" ] + }, { "type": "effect_type", "id": "mutagen_plantkin", diff --git a/data/mods/Xedra_Evolved/eocs/hedge_research_eocs.json b/data/mods/Xedra_Evolved/eocs/hedge_research_eocs.json new file mode 100644 index 0000000000000..36a00008c195b --- /dev/null +++ b/data/mods/Xedra_Evolved/eocs/hedge_research_eocs.json @@ -0,0 +1,137 @@ +[ + { + "//": "Rolls below should be -u_skill('deduction') + rng(-2,8) + rng(-2,8)-. This is an average of 6 + Deduction per research period.", + "id": "ACT_XE_DECIPHERING_HEDGE_TOME", + "type": "activity_type", + "activity_level": "NO_EXERCISE", + "verb": "deciphering the secrets of the occult", + "based_on": "time", + "can_resume": false, + "auto_needs": true, + "do_turn_eoc": "EOC_DECIPHERING_NEW_HEDGE_TOME_TIME_TRACKER", + "completion_eoc": "EOC_DECIPHERING_NEW_HEDGE_TOME_PACE_SELF" + }, + { + "type": "effect_on_condition", + "id": "EOC_DECIPHERING_NEW_HEDGE_TOME_TIME_TRACKER", + "condition": { "math": [ "u_most_recent_hedge_research_progress", "<=", "u_most_recent_hedge_research_difficulty" ] }, + "effect": [ { "math": [ "u_most_recent_hedge_research_time", "+=", "1" ] } ], + "false_effect": [ { "run_eocs": { "u_val": "latest_completion_eoc" } } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_DECIPHERING_NEW_HEDGE_TOME_PACE_SELF", + "effect": [ + { "u_message": "You finish your study session.", "type": "neutral" }, + { "u_lose_effect": "effect_xe_deciphering_hedge_tome" } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_MAGIC_CANCELLING_ACTIVITY_CANCELS_RESEARCH", + "eoc_type": "EVENT", + "required_event": "character_finished_activity", + "condition": { + "and": [ + { "compare_string": [ "ACT_XE_DECIPHERING_HEDGE_TOME_NEW_POWER", { "context_val": "activity" } ] }, + { "u_has_effect": "effect_xe_deciphering_hedge_tome" } + ] + }, + "effect": [ { "u_lose_effect": "effect_xe_deciphering_hedge_tome" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_RESEARCH_FOCUS_DRAIN", + "condition": { "u_has_effect": "effect_xe_deciphering_hedge_tome" }, + "effect": [ + { "if": { "math": [ "u_val('focus')", ">", "5" ] }, "then": { "math": [ "u_val('focus')", "-=", "1" ] } }, + { "queue_eocs": "EOC_HEDGE_RESEARCH_FOCUS_DRAIN", "time_in_future": [ "1 minutes", "3 minutes" ] } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE", + "condition": { "u_has_effect": "effect_xe_deciphering_hedge_tome" }, + "effect": [ + { + "run_eocs": [ + { + "id": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE_2", + "condition": { "math": [ "u_most_recent_hedge_research_time_upper_limit", "<=", "302400" ] }, + "effect": [ + { + "run_eocs": [ + { + "id": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE_3", + "condition": { "math": [ "u_most_recent_hedge_research_progress", "<=", "u_most_recent_hedge_research_difficulty" ] }, + "effect": [ + { "math": [ "u_most_recent_hedge_research_progress", "+=", "u_skill('deduction') + rng(-2,8) + rng(-2,8)" ] }, + { + "u_run_inv_eocs": "random", + "search_data": [ { "id": "spellbook_hedge_abramelin_the_mage" } ], + "true_eocs": [ + { + "id": "EOC_HEDGE_RESEARCH_ABRAMELIN_THE_MAGE_WRITE_VALUES", + "effect": [ + { "math": [ "n_most_recent_hedge_research_time", "=", "u_most_recent_hedge_research_time" ] }, + { + "math": [ "n_most_recent_hedge_research_progress", "=", "u_most_recent_hedge_research_progress" ] + } + ] + } + ] + }, + { + "if": { "math": [ "u_val('focus')", ">", "5" ] }, + "then": { "math": [ "u_val('focus')", "-=", "5" ] } + }, + { + "queue_eocs": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE", + "time_in_future": [ + { "math": [ "3000 / min( scaling_factor(u_val('intelligence') ),2)" ] }, + { "math": [ "4200 / min( scaling_factor(u_val('intelligence') ),2)" ] } + ] + } + ], + "false_effect": [ + { + "run_eocs": [ + { + "id": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE_COMPLETION", + "condition": { "math": [ "u_most_recent_hedge_research_progress", ">", "u_most_recent_hedge_research_difficulty" ] }, + "effect": [ + { "u_lose_effect": "effect_xe_deciphering_hedge_tome" }, + { + "u_message": "You've done it. All the pieces finally fall into place. You've unlocked the occult secrets of this work, and can now study the rituals within.", + "popup": true + }, + { "math": [ "u_deciphered_spellbook_hedge_abramelin_the_mage", "=", "1" ] } + ] + } + ] + } + ] + } + ] + } + ], + "false_effect": [ + { "u_message": "You can't make heads of tails of this work. You'll have to start over.", "popup": true }, + { "u_lose_effect": "effect_xe_deciphering_hedge_tome" }, + { + "u_run_inv_eocs": "random", + "search_data": [ { "id": "spellbook_hedge_abramelin_the_mage" } ], + "true_eocs": [ + { + "id": "EOC_HEDGE_RESEARCH_ABRAMELIN_THE_MAGE_WRITE_VALUES_2", + "effect": [ { "math": [ "n_already_failed_research", "=", "1" ] } ] + } + ] + } + ] + } + ] + } + ] + } +] diff --git a/data/mods/Xedra_Evolved/eocs/profession_eocs.json b/data/mods/Xedra_Evolved/eocs/profession_eocs.json new file mode 100644 index 0000000000000..ac9ee7faa2590 --- /dev/null +++ b/data/mods/Xedra_Evolved/eocs/profession_eocs.json @@ -0,0 +1,10 @@ +[ + { + "type": "effect_on_condition", + "id": "EOC_XE_XE_OPERATIVE_MAGIC_SQUARES_BOOK_UNDERSTANDING", + "eoc_type": "EVENT", + "required_event": "game_start", + "condition": { "u_profession": "xe_hedge_mage_magic_squares" }, + "effect": [ { "math": [ "u_deciphered_spellbook_hedge_abramelin_the_mage", "=", "1" ] } ] + } +] diff --git a/data/mods/Xedra_Evolved/itemgroups/itemgroups.json b/data/mods/Xedra_Evolved/itemgroups/itemgroups.json index 3d28f6be190dc..66f504e14ac5c 100644 --- a/data/mods/Xedra_Evolved/itemgroups/itemgroups.json +++ b/data/mods/Xedra_Evolved/itemgroups/itemgroups.json @@ -403,7 +403,8 @@ { "item": "spellbook_hedge_blood_book", "prob": 2 }, { "item": "spellbook_hedge_ward_dreams", "prob": 3 }, { "item": "spellbook_hedge_snare_changelings", "prob": 1 }, - { "item": "spellbook_hedge_bathhouse_midnight", "prob": 1 } + { "item": "spellbook_hedge_bathhouse_midnight", "prob": 1 }, + { "item": "spellbook_hedge_abramelin_the_mage", "prob": 1 } ] }, { diff --git a/data/mods/Xedra_Evolved/items/hedge_magic_items.json b/data/mods/Xedra_Evolved/items/hedge_magic_items.json index 3f0d66ed13deb..6b95ffb00a5cb 100644 --- a/data/mods/Xedra_Evolved/items/hedge_magic_items.json +++ b/data/mods/Xedra_Evolved/items/hedge_magic_items.json @@ -1,4 +1,19 @@ [ + { + "abstract": "magic_square_base", + "name": "Magic Square abstract", + "description": "SATOR AREPO TENET OPERA ROTAS.", + "type": "TOOL", + "weight": "3 g", + "color": "white", + "symbol": "`", + "price": "0 cent", + "price_postapoc": "0 cent", + "material": [ "paper" ], + "flags": [ "TINDER", "PAPER_SHAPED", "SINGLE_USE" ], + "volume": "6 ml", + "longest_side": "297 mm" + }, { "id": "aura_ward_off_rain", "type": "ARMOR", @@ -262,5 +277,146 @@ "description": "Activate to remove the mantle and end the magic.", "effect_on_conditions": [ "EOC_HEDGE_TURN_INTO_BEAR_REMOVE_ITEM" ] } + }, + { + "type": "BOOK", + "id": "item_walk_on_water_magic_square", + "copy-from": "magic_square_base", + "name": { "str": "magic square (To Walk Upon the Water)", "str_pl": "magic squares (To Walk Upon the Water)" }, + "description": "A piece of paper. A magic square is carefully written on it.", + "extend": { "flags": [ "HEDGE_ENCHANTED" ] }, + "use_action": { + "type": "effect_on_conditions", + "description": "Activate the charm using the magic square.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_WALK_ON_WATER_MAGIC_SQUARE", + "effect": [ + { "u_assign_activity": "ACT_GENERIC_EOC", "duration": 2.5 }, + { "u_add_effect": "effect_hedge_walk_on_water_magic_square", "duration": 1800, "intensity": 30 } + ] + } + ] + } + }, + { + "type": "BOOK", + "id": "item_breathe_water_magic_square", + "copy-from": "magic_square_base", + "name": { "str": "magic square (To Operate Under the Water)", "str_pl": "magic squares (To Operate Under the Water)" }, + "description": "A piece of paper. A magic square is carefully written on it.", + "extend": { "flags": [ "HEDGE_ENCHANTED" ] }, + "use_action": { + "type": "effect_on_conditions", + "description": "Activate the charm using the magic square.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_BREATHE_WATER_MAGIC_SQUARE", + "effect": [ + { "u_assign_activity": "ACT_GENERIC_EOC", "duration": 2.5 }, + { "u_add_effect": "effect_hedge_breathe_water_magic_square", "duration": 7200, "intensity": 120 } + ] + } + ] + } + }, + { + "type": "BOOK", + "id": "item_bash_terrain_magic_square", + "copy-from": "magic_square_base", + "name": { + "str": "magic square (To Demolish Buildings and Strongholds)", + "str_pl": "magic squares (To Demolish Buildings and Strongholds)" + }, + "description": "A piece of paper. A magic square is carefully written on it.", + "extend": { "flags": [ "HEDGE_ENCHANTED" ] }, + "use_action": { + "type": "effect_on_conditions", + "description": "Activate the charm using the magic square.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_BASH_TERRAIN_MAGIC_SQUARE", + "effect": [ + { "u_assign_activity": "ACT_GENERIC_EOC", "duration": 2.5 }, + { "u_cast_spell": { "id": "hedge_bash_terrain_magic_square_real" }, "targeted": true } + ] + } + ] + } + }, + { + "type": "BOOK", + "id": "item_armed_men_magic_square", + "copy-from": "magic_square_base", + "name": { "str": "magic square (To Cause Armed Men to Appear)", "str_pl": "magic squares (To Cause Armed Men to Appear)" }, + "description": "A piece of paper. A magic square is carefully written on it.", + "extend": { "flags": [ "HEDGE_ENCHANTED" ] }, + "use_action": { + "type": "effect_on_conditions", + "description": "Activate the charm using the magic square.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_ARMED_MEN_MAGIC_SQUARE", + "effect": [ + { "u_assign_activity": "ACT_GENERIC_EOC", "duration": 2.5 }, + { + "u_spawn_monster": "GROUP_HEDGE_TO_CAUSE_ARMED_MEN", + "real_count": { "math": [ "2 + rand(3)" ] }, + "group": true, + "min_radius": 1, + "max_radius": 3, + "lifespan": [ "15 minutes", "45 minutes" ], + "spawn_message": "An armed warrior appears.", + "spawn_message_plural": "Several armed warriors appear." + } + ] + } + ] + } + }, + { + "type": "BOOK", + "id": "item_food_or_drink_magic_square", + "copy-from": "magic_square_base", + "name": { + "str": "magic square (To Cause the Spirits to Bring us Anything We May Wish to Eat or to Drink)", + "str_pl": "magic squares (To Cause the Spirits to Bring us Anything We May Wish to Eat or to Drink)" + }, + "description": "A piece of paper. A magic square is carefully written on it.", + "extend": { "flags": [ "HEDGE_ENCHANTED" ] }, + "use_action": { + "type": "effect_on_conditions", + "description": "Activate the charm using the magic square.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_FOOR_OR_DRINK_MAGIC_SQUARE", + "effect": [ { "u_assign_activity": "ACT_GENERIC_EOC", "duration": 2.5 }, { "run_eocs": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR" } ] + } + ] + } + }, + { + "type": "BOOK", + "id": "item_invisibility_magic_square", + "copy-from": "magic_square_base", + "name": { + "str": "magic square (To Render Oneself Invisible Unto Every Person)", + "str_pl": "magic squares (To Render Oneself Invisible Unto Every Person)" + }, + "description": "A piece of paper. A magic square is carefully written on it.", + "extend": { "flags": [ "HEDGE_ENCHANTED" ] }, + "use_action": { + "type": "effect_on_conditions", + "description": "Activate the charm using the magic square.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_INVISIBILITY_MAGIC_SQUARE", + "effect": [ + { "u_assign_activity": "ACT_GENERIC_EOC", "duration": 2.5 }, + { "u_add_effect": "effect_invisibility_magic_square", "duration": 4620, "intensity": 77 } + ] + } + ] + } } ] diff --git a/data/mods/Xedra_Evolved/items/spell_learning_items/spellbooks_hedge.json b/data/mods/Xedra_Evolved/items/spell_learning_items/spellbooks_hedge.json index db0b870a6fe55..ac4279dab1525 100644 --- a/data/mods/Xedra_Evolved/items/spell_learning_items/spellbooks_hedge.json +++ b/data/mods/Xedra_Evolved/items/spell_learning_items/spellbooks_hedge.json @@ -130,5 +130,113 @@ "type": "learn_spell", "spells": [ "hedge_clairvoyance_cone", "hedge_walk_on_water", "hedge_evil_eye_ward", "hedge_cure_cold_or_flu" ] } + }, + { + "id": "spellbook_hedge_abramelin_the_mage", + "type": "GENERIC", + "name": { + "str": "The Book of the Sacred Magic of Abramelin the Mage", + "str_pl": "copies of The Book of the Sacred Magic of Abramelin the Mage" + }, + "description": "Translated from the French edition by Samuel L MacGregor Mathers, this tome compiles the journeys of a man named Abraham of Worms to Egypt, where he learned occult secrets from the wizard Abramelin who lived in a small town near the Nile. The magic contained within focuses mostly on the creation of magic squares which, when used in ceremonies by an initiate, provide magical effects.", + "weight": "539 g", + "volume": "674 ml", + "material": [ "paper" ], + "looks_like": "paper", + "symbol": "?", + "color": "dark_gray", + "use_action": { + "type": "effect_on_conditions", + "description": "Study the occult text.", + "effect_on_conditions": [ + { + "id": "EOC_HEDGE_RESEARCH_ABRAMELIN_THE_MAGE", + "//": "Max research time before failure is 84 hours. Average result of 504 after 84 hours of study with Deduction 0. Studying drains focus, but focus is not taken into account to determine progress or success at this time.", + "condition": { "math": [ "u_deciphered_spellbook_hedge_abramelin_the_mage", "!=", "1" ] }, + "effect": [ + { "set_string_var": "spellbook_hedge_abramelin_the_mage", "target_var": { "u_val": "latest_studied_occult_text_name" } }, + { + "set_string_var": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE_COMPLETION", + "target_var": { "u_val": "latest_completion_eoc" } + }, + { "math": [ "u_most_recent_hedge_research_time_upper_limit", "=", "302400" ] }, + { + "u_run_inv_eocs": "random", + "search_data": [ { "id": "spellbook_hedge_abramelin_the_mage" } ], + "true_eocs": [ + { + "id": "EOC_HEDGE_RESEARCH_ABRAMELIN_THE_MAGE_SET_DIFFICULTY", + "condition": { "math": [ "n_already_failed_research", "==", "1" ] }, + "effect": [ { "math": [ "u_most_recent_hedge_research_difficulty", "=", "720" ] } ], + "false_effect": [ { "math": [ "u_most_recent_hedge_research_difficulty", "=", "800" ] } ] + }, + { + "id": "EOC_HEDGE_RESEARCH_ABRAMELIN_THE_MAGE_READ_VALUES", + "effect": [ + { "math": [ "u_most_recent_hedge_research_time", "=", "n_most_recent_hedge_research_time" ] }, + { + "math": [ "u_most_recent_hedge_research_progress", "=", "n_most_recent_hedge_research_progress" ] + } + ] + } + ] + }, + { "u_assign_activity": "ACT_XE_DECIPHERING_HEDGE_TOME", "duration": "8 hours" }, + { "u_add_effect": "effect_xe_deciphering_hedge_tome", "duration": "8 hours" }, + { + "queue_eocs": "EOC_HEDGE_RESEARCH_PROGRESS_ABRAMELIN_THE_MAGE", + "time_in_future": [ + { "math": [ "3000 / min( scaling_factor(u_val('intelligence') ),2)" ] }, + { "math": [ "4200 / min( scaling_factor(u_val('intelligence') ),2)" ] } + ] + }, + { + "queue_eocs": "EOC_HEDGE_RESEARCH_FOCUS_DRAIN", + "time_in_future": [ + { "math": [ "3000 / min( scaling_factor(u_val('intelligence') ),2)" ] }, + { "math": [ "4200 / min( scaling_factor(u_val('intelligence') ),2)" ] } + ] + } + ], + "false_effect": [ + { "u_spawn_item": "spellbook_hedge_abramelin_the_mage_spell_stub", "suppress_message": true }, + { + "run_eocs": [ + { + "id": "EOC_HEDGE_USING_ABRAMELIN_THE_MAGE", + "effect": [ + { + "u_run_inv_eocs": "random", + "search_data": [ { "id": "spellbook_hedge_abramelin_the_mage_spell_stub" } ], + "true_eocs": [ { "id": "EOC_HEDGE_USING_ABRAMELIN_THE_MAGE_ACTIVATE", "effect": { "u_activate": "learn_spell" } } ] + } + ] + } + ] + }, + { "u_remove_item_with": "spellbook_hedge_abramelin_the_mage_spell_stub" } + ] + } + ] + } + }, + { + "id": "spellbook_hedge_abramelin_the_mage_spell_stub", + "type": "BOOK", + "category": "manuals", + "copy-from": "magic_square_base", + "name": { "str_sp": "The Real Actual Spell Book of the Sacred Magic of Abramelin the Mage" }, + "description": "The temporary item that teaches you spells.", + "use_action": { + "type": "learn_spell", + "spells": [ + "hedge_walk_on_water_magic_square", + "hedge_breathe_water_magic_square", + "hedge_bash_terrain_magic_square", + "hedge_food_or_drink_magic_square", + "hedge_armed_men_magic_square", + "hedge_invisibility_magic_square" + ] + } } ] diff --git a/data/mods/Xedra_Evolved/monsters/monstergroup.json b/data/mods/Xedra_Evolved/monsters/monstergroup.json index d588cf14bf6d1..e1a20053f9495 100644 --- a/data/mods/Xedra_Evolved/monsters/monstergroup.json +++ b/data/mods/Xedra_Evolved/monsters/monstergroup.json @@ -339,5 +339,15 @@ { "monster": "mon_mi_go_stalking_warper", "weight": 200, "cost_multiplier": 2 }, { "monster": "mon_mi_go_stalking_warper", "weight": 50, "cost_multiplier": 5, "pack_size": [ 2, 3 ] } ] + }, + { + "type": "monstergroup", + "name": "GROUP_HEDGE_TO_CAUSE_ARMED_MEN", + "monsters": [ + { "monster": "mon_hedge_armed_warrior_sword", "weight": 400 }, + { "monster": "mon_hedge_armed_warrior_spear", "weight": 400 }, + { "monster": "mon_hedge_armored_warrior_axe", "weight": 200 }, + { "monster": "mon_hedge_armored_warrior_mace", "weight": 200 } + ] } ] diff --git a/data/mods/Xedra_Evolved/monsters/summoned_monsters.json b/data/mods/Xedra_Evolved/monsters/summoned_monsters.json new file mode 100644 index 0000000000000..4fca68c6f61a3 --- /dev/null +++ b/data/mods/Xedra_Evolved/monsters/summoned_monsters.json @@ -0,0 +1,43 @@ +[ + { + "type": "MONSTER", + "id": "mon_hedge_armored_warrior_mace", + "copy-from": "mon_feral_armored_mace", + "name": { "str": "armored warrior with mace", "str_pl": "armored warriors with maces" }, + "looks_like": "mon_feral_armored_mace", + "description": "Clad in ancient armor and with a mace in hand, this warrior was summoned by magic to defend you.", + "default_faction": "player", + "delete": { "special_attacks": [ "BROWSE", "EAT_FOOD", "PARROT" ] } + }, + { + "type": "MONSTER", + "id": "mon_hedge_armored_warrior_axe", + "copy-from": "mon_feral_armored_battleaxe", + "name": { "str": "armored warrior with axe", "str_pl": "armored warriors with axes" }, + "looks_like": "mon_feral_armored_battleaxe", + "description": "Clad in ancient armor and with a battleaxe in hand, this warrior was summoned by magic to defend you.", + "default_faction": "player", + "delete": { "special_attacks": [ "BROWSE", "EAT_FOOD", "PARROT" ] } + }, + { + "type": "MONSTER", + "id": "mon_hedge_armed_warrior_spear", + "copy-from": "mon_feral_sapien_spear", + "name": { "str": "warrior with spear", "str_pl": "warriors with spears" }, + "looks_like": "mon_feral_sapien_spear", + "description": "Clad in leather armor and with a spear in hand, this warrior was summoned by magic to defend you.", + "default_faction": "player", + "delete": { "special_attacks": [ "PARROT_AT_DANGER" ] } + }, + { + "type": "MONSTER", + "id": "mon_hedge_armed_warrior_sword", + "copy-from": "mon_feral_fancy_rapier", + "name": { "str": "warrior with sword", "str_pl": "warriors with sword" }, + "looks_like": "mon_feral_fancy_rapier", + "description": "Clad in leather armor and with a sword in hand, this warrior was summoned by magic to defend you.", + "default_faction": "player", + "extend": { "armor": { "bash": 9, "cut": 14, "acid": 4, "bullet": 18 } }, + "delete": { "special_attacks": [ "BROWSE", "EAT_FOOD", "PARROT" ] } + } +] diff --git a/data/mods/Xedra_Evolved/player/professions.json b/data/mods/Xedra_Evolved/player/professions.json index 5cb0379de723b..5a529176373ab 100644 --- a/data/mods/Xedra_Evolved/player/professions.json +++ b/data/mods/Xedra_Evolved/player/professions.json @@ -453,6 +453,55 @@ "female": { "entries": [ { "item": "sports_bra" }, { "item": "boxer_shorts" } ] } } }, + { + "type": "profession", + "id": "xe_hedge_mage_magic_squares", + "name": "XEDRA Operative, Department of Extra-Normal Capabilities, SATOR Division", + "description": "You joined XEDRA during the years leading up to the Cataclysm, and they told you that you fit the profile of a SATOR agent. At the time you had no idea what they meant, and they gave you a couple days to process when you learned that magic was real, the enemies of the United States possessed it, and they wanted you to learn it too. When they sat you down and had you practice writing letters into patterns for days on end you wondered if you had made a mistake, but when one of those squares let you summon a loaf of bread out of thin air for lunch, you changed your tune pretty quickly.", + "points": 4, + "traits": [ "HEDGE_MAGIC" ], + "skills": [ + { "level": 2, "name": "dodge" }, + { "level": 4, "name": "gun" }, + { "level": 4, "name": "pistol" }, + { "level": 3, "name": "deduction" } + ], + "proficiencies": [ "prof_auto_pistols_familiar" ], + "spells": [ + { "id": "hedge_walk_on_water_magic_square", "level": 1 }, + { "id": "hedge_breathe_water_magic_square", "level": 1 }, + { "id": "hedge_bash_terrain_magic_square", "level": 1 }, + { "id": "hedge_food_or_drink_magic_square", "level": 1 }, + { "id": "hedge_armed_men_magic_square", "level": 1 }, + { "id": "hedge_invisibility_magic_square", "level": 1 } + ], + "items": { + "both": { + "entries": [ + { "item": "pants" }, + { "item": "dress_shirt" }, + { "item": "tie_skinny" }, + { "item": "blazer" }, + { "item": "wristwatch" }, + { "item": "socks" }, + { "item": "dress_shoes" }, + { "group": "charged_smart_phone" }, + { "group": "charged_two_way_radio" }, + { "item": "black_pen", "charges": 100 }, + { "item": "paper", "charges": 15 }, + { "group": "army_mags_usp9" }, + { "item": "usp_9mm", "ammo-item": "9mm", "charges": 15, "container-item": "shoulder_holster" }, + { "item": "spellbook_hedge_abramelin_the_mage" }, + { "item": "item_walk_on_water_magic_square", "count": 2 }, + { "item": "item_food_or_drink_magic_square", "count": 3 }, + { "item": "item_invisibility_magic_square", "count": 1 }, + { "item": "item_armed_men_magic_square", "count": 1 } + ] + }, + "male": { "entries": [ { "item": "briefs" } ] }, + "female": { "entries": [ { "item": "bra" }, { "item": "panties" } ] } + } + }, { "type": "profession", "subtype": "hobby", diff --git a/data/mods/Xedra_Evolved/requirements/spell_components.json b/data/mods/Xedra_Evolved/requirements/spell_components.json index 1735b8029c3cc..dda59a7555f6b 100644 --- a/data/mods/Xedra_Evolved/requirements/spell_components.json +++ b/data/mods/Xedra_Evolved/requirements/spell_components.json @@ -197,5 +197,48 @@ "type": "requirement", "tools": [ [ [ "candle_lit", -1 ] ] ], "components": [ [ [ "salt", 15 ] ], [ [ "wild_herbs", 30 ] ] ] + }, + { + "id": "spell_components_hedge_magic_square_four_hours", + "type": "requirement", + "tools": [ + [ [ "candle_lit", -1 ] ], + [ [ "pen", 4 ], [ "pencil", 4 ], [ "blue_pen", 4 ], [ "green_pen", 4 ], [ "black_pen", 4 ], [ "red_pen", 4 ] ] + ], + "components": [ [ [ "paper", 1 ] ] ] + }, + { + "id": "spell_components_hedge_magic_square_six_hours", + "type": "requirement", + "tools": [ + [ [ "candle_lit", -1 ] ], + [ [ "pen", 4 ], [ "pencil", 6 ], [ "blue_pen", 6 ], [ "green_pen", 6 ], [ "black_pen", 6 ], [ "red_pen", 6 ] ] + ], + "components": [ [ [ "paper", 2 ] ] ] + }, + { + "id": "spell_components_hedge_magic_square_eight_hours", + "type": "requirement", + "tools": [ + [ [ "candle_lit", -1 ] ], + [ [ "pen", 8 ], [ "pencil", 8 ], [ "blue_pen", 8 ], [ "green_pen", 8 ], [ "black_pen", 8 ], [ "red_pen", 8 ] ] + ], + "components": [ [ [ "paper", 2 ] ] ] + }, + { + "id": "spell_components_hedge_magic_square_twelve_hours", + "type": "requirement", + "tools": [ + [ [ "candle_lit", -1 ] ], + [ + [ "pen", 12 ], + [ "pencil", 12 ], + [ "blue_pen", 12 ], + [ "green_pen", 12 ], + [ "black_pen", 12 ], + [ "red_pen", 12 ] + ] + ], + "components": [ [ [ "paper", 3 ] ] ] } ] diff --git a/data/mods/Xedra_Evolved/scenario.json b/data/mods/Xedra_Evolved/scenario.json index f02fcee319856..9b5913c4c12c4 100644 --- a/data/mods/Xedra_Evolved/scenario.json +++ b/data/mods/Xedra_Evolved/scenario.json @@ -14,7 +14,8 @@ "xe_eater", "xe_dreamer", "xe_inventor", - "xe_dreamsmith" + "xe_dreamsmith", + "xe_hedge_mage_magic_squares" ] }, "id": "heli_crash" diff --git a/data/mods/Xedra_Evolved/spells/hedge_magic_eocs.json b/data/mods/Xedra_Evolved/spells/hedge_magic_eocs.json index 9e4fee4ef8e72..e23da3949c93e 100644 --- a/data/mods/Xedra_Evolved/spells/hedge_magic_eocs.json +++ b/data/mods/Xedra_Evolved/spells/hedge_magic_eocs.json @@ -7,7 +7,11 @@ { "type": "effect_on_condition", "id": "EOC_HEDGE_MAGIC_REMOVE_ATTACK_EFFECTS", - "effect": [ { "u_remove_item_with": "hedge_witchlight" }, { "u_lose_trait": "HEDGE_FOREST_BUSH_SHAPE" } ] + "effect": [ + { "u_remove_item_with": "hedge_witchlight" }, + { "u_lose_trait": "HEDGE_FOREST_BUSH_SHAPE" }, + { "u_lose_effect": "effect_invisibility_magic_square" } + ] }, { "type": "effect_on_condition", @@ -20,7 +24,25 @@ { "type": "effect_on_condition", "id": "EOC_HEDGE_MAGIC_MELEE_EOC_CONDITIONS", - "condition": { "or": [ { "u_has_trait": "HEDGE_FOREST_BUSH_SHAPE" }, { "u_has_item": "hedge_witchlight" } ] }, + "condition": { + "or": [ + { "u_has_trait": "HEDGE_FOREST_BUSH_SHAPE" }, + { "u_has_item": "hedge_witchlight" }, + { "u_has_effect": "effect_invisibility_magic_square" } + ] + }, + "effect": [ ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_MAGIC_RANGED_EOC_CONDITIONS", + "condition": { + "or": [ + { "u_has_trait": "HEDGE_FOREST_BUSH_SHAPE" }, + { "u_has_item": "hedge_witchlight" }, + { "u_has_effect": "effect_invisibility_magic_square" } + ] + }, "effect": [ ] }, { @@ -44,7 +66,7 @@ "id": "EOC_HEDGE_MAGIC_RANGED_MONSTER_CANCEL", "eoc_type": "EVENT", "required_event": "character_ranged_attacks_monster", - "condition": { "test_eoc": "EOC_HEDGE_MAGIC_MELEE_EOC_CONDITIONS" }, + "condition": { "test_eoc": "EOC_HEDGE_MAGIC_RANGED_EOC_CONDITIONS" }, "effect": [ { "run_eocs": [ "EOC_HEDGE_MAGIC_REMOVE_ATTACK_EFFECTS" ] } ] }, { @@ -52,7 +74,7 @@ "id": "EOC_HEDGE_MAGIC_RANGED_CHARACTER_CANCEL", "eoc_type": "EVENT", "required_event": "character_ranged_attacks_character", - "condition": { "test_eoc": "EOC_HEDGE_MAGIC_MELEE_EOC_CONDITIONS" }, + "condition": { "test_eoc": "EOC_HEDGE_MAGIC_RANGED_EOC_CONDITIONS" }, "effect": [ { "run_eocs": [ "EOC_HEDGE_MAGIC_REMOVE_ATTACK_EFFECTS" ] } ] }, { @@ -472,5 +494,84 @@ ] } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR", + "effect": [ + { + "run_eoc_selector": [ + "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_MEAT", + "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_CHEESE", + "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_FISH", + "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_BREAD", + "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_WINE" + ], + "allow_cancel": true, + "names": [ "Summon meat", "Summon cheese", "Summon fish", "Summon bread", "Summon wine" ], + "title": "Conjure which victuals?", + "descriptions": [ + "Ask the spirits to summon some meat for you to eat.", + "Ask the spirits to summon some cheese for you to eat.", + "Ask the spirits to summon some fish for you to eat.", + "Ask the spirits to summon some bread for you to eat.", + "Ask the spirits to summon a bottle of wine for you to drink." + ] + } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_MEAT", + "effect": [ + { + "u_message": "There is a gust of wind, a sparkle in the air, and a faint murmur of sound, and some cooked meat appears before you." + }, + { "u_spawn_item": "meat_cooked", "count": { "math": [ "rand(3) + 1" ] }, "suppress_message": true } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_CHEESE", + "effect": [ + { + "u_message": "There is a gust of wind, a sparkle in the air, and a faint murmur of sound, and some hard cheese appears before you." + }, + { "u_spawn_item": "cheese_hard", "count": { "math": [ "rand(11) + 4" ] }, "suppress_message": true } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_FISH", + "effect": [ + { + "u_message": "There is a gust of wind, a sparkle in the air, and a faint murmur of sound, and some cooked fish appears before you." + }, + { "u_spawn_item": "fish_cooked", "count": { "math": [ "rand(3) + 1" ] }, "suppress_message": true } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_BREAD", + "effect": [ + { + "u_message": "There is a gust of wind, a sparkle in the air, and a faint murmur of sound, and some fresh bread appears before you." + }, + { "u_spawn_item": "bread", "count": { "math": [ "rand(6) + 2" ] }, "suppress_message": true } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_HEDGE_FOOD_OR_DRINK_SELECTOR_WINE", + "effect": [ + { + "u_message": "There is a gust of wind, a sparkle in the air, and a faint murmur of sound, and a bottle of wine appears before you." + }, + { + "if": { "math": [ "rand(1)", "==", "1" ] }, + "then": [ { "u_spawn_item": "wine_riesling", "container": "bottle_glass", "count": 3, "suppress_message": true } ], + "else": [ { "u_spawn_item": "wine_noir", "container": "bottle_glass", "count": 3, "suppress_message": true } ] + } + ] } ] diff --git a/data/mods/Xedra_Evolved/spells/hedge_magic_spells.json b/data/mods/Xedra_Evolved/spells/hedge_magic_spells.json index 2f50e8f780201..7788177f8d1c5 100644 --- a/data/mods/Xedra_Evolved/spells/hedge_magic_spells.json +++ b/data/mods/Xedra_Evolved/spells/hedge_magic_spells.json @@ -411,7 +411,7 @@ "shape": "blast", "components": "spell_components_hedge_walk_on_water", "max_level": 1, - "base_casting_time": 1000 + "base_casting_time": 6000 }, { "id": "hedge_bless_steel_weapon", @@ -447,5 +447,145 @@ "min_range": 1, "max_range": 1, "targeted_monster_species": [ "NETHER", "ABERRATION", "HORROR", "NETHER_EMANATION" ] + }, + { + "id": "hedge_walk_on_water_magic_square", + "type": "SPELL", + "name": "To Walk Upon the Water", + "description": "Create a magic square that can later be used in a short ritual to walk across the surface of the water.", + "message": "Focusing your mind and muttering the charms and spells under your breath, you carefully write down the patterns of the magic square.", + "flags": [ "VERBAL", "SOMATIC", "NO_FAIL", "PERMANENT", "PERMANENT_ALL_LEVELS" ], + "valid_targets": [ "self" ], + "difficulty": 1, + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "effect": "spawn_item", + "effect_str": "item_walk_on_water_magic_square", + "shape": "blast", + "components": "spell_components_hedge_magic_square_four_hours", + "max_level": 1, + "min_damage": 1, + "max_damage": 1, + "base_casting_time": 1440000 + }, + { + "id": "hedge_breathe_water_magic_square", + "type": "SPELL", + "name": "To Operate Under the Water", + "description": "Create a magic square that can later be used in a short ritual to breathe underwater.", + "message": "Focusing your mind and muttering the charms and spells under your breath, you carefully write down the patterns of the magic square.", + "flags": [ "VERBAL", "SOMATIC", "NO_FAIL", "PERMANENT", "PERMANENT_ALL_LEVELS" ], + "valid_targets": [ "self" ], + "difficulty": 1, + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "effect": "spawn_item", + "effect_str": "item_breathe_water_magic_square", + "shape": "blast", + "components": "spell_components_hedge_magic_square_six_hours", + "max_level": 1, + "min_damage": 1, + "max_damage": 1, + "base_casting_time": 2160000 + }, + { + "id": "hedge_bash_terrain_magic_square", + "type": "SPELL", + "name": "To Demolish Buildings and Strongholds", + "description": "Create a magic square that can later be used in a short ritual to do massive damage to a nearby structure.", + "message": "Focusing your mind and muttering the charms and spells under your breath, you carefully write down the patterns of the magic square.", + "flags": [ "VERBAL", "SOMATIC", "NO_FAIL", "PERMANENT", "PERMANENT_ALL_LEVELS" ], + "valid_targets": [ "self" ], + "difficulty": 1, + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "effect": "spawn_item", + "effect_str": "item_bash_terrain_magic_square", + "shape": "blast", + "components": "spell_components_hedge_magic_square_six_hours", + "max_level": 1, + "min_damage": 1, + "max_damage": 1, + "base_casting_time": 2160000 + }, + { + "id": "hedge_bash_terrain_magic_square_real", + "type": "SPELL", + "name": "To Demolish Buildings and Strongholds Real", + "description": "The actual spell for To Demolish Buildings and Strongholds. It's a bug if you have it directly.", + "message": "", + "teachable": false, + "valid_targets": [ "hostile", "ground", "ally" ], + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "flags": [ "LOUD", "NO_HANDS", "NO_LEGS", "NO_PROJECTILE", "IGNORE_WALLS", "RANDOM_DAMAGE" ], + "effect": "bash", + "shape": "cone", + "min_damage": 300, + "max_damage": 400, + "min_range": 13, + "max_range": 13, + "min_aoe": 90, + "max_aoe": 90 + }, + { + "id": "hedge_armed_men_magic_square", + "type": "SPELL", + "name": "To Cause Armed Men to Appear", + "description": "Create a magic square to summon an ethereal group of soldiers who will attack your enemies.", + "message": "Focusing your mind and muttering the charms and spells under your breath, you carefully write down the patterns of the magic square.", + "flags": [ "VERBAL", "SOMATIC", "NO_FAIL", "PERMANENT", "PERMANENT_ALL_LEVELS" ], + "valid_targets": [ "self" ], + "difficulty": 1, + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "effect": "spawn_item", + "effect_str": "item_armed_men_magic_square", + "shape": "blast", + "components": "spell_components_hedge_magic_square_eight_hours", + "max_level": 1, + "min_damage": 1, + "max_damage": 1, + "base_casting_time": 2880000 + }, + { + "id": "hedge_food_or_drink_magic_square", + "type": "SPELL", + "name": "To Cause the Spirits to Bring us Anything We May Wish to Eat or to Drink", + "description": "Create a magic square to cause an ethereal spirit to bring wine, meat, cheese, or bread to you.", + "message": "Focusing your mind and muttering the charms and spells under your breath, you carefully write down the patterns of the magic square.", + "flags": [ "VERBAL", "SOMATIC", "NO_FAIL", "PERMANENT", "PERMANENT_ALL_LEVELS" ], + "valid_targets": [ "self" ], + "difficulty": 1, + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "effect": "spawn_item", + "effect_str": "item_food_or_drink_magic_square", + "shape": "blast", + "components": "spell_components_hedge_magic_square_eight_hours", + "max_level": 1, + "min_damage": 1, + "max_damage": 1, + "base_casting_time": 2880000 + }, + { + "id": "hedge_invisibility_magic_square", + "type": "SPELL", + "name": "To Render Oneself Invisible Unto Every Person", + "description": "Create a magic square to that will cause you to turn completely invisible. Violent action will reveal your presence.", + "message": "Focusing your mind and muttering the charms and spells under your breath, you carefully write down the patterns of the magic square.", + "flags": [ "VERBAL", "SOMATIC", "NO_FAIL", "PERMANENT", "PERMANENT_ALL_LEVELS" ], + "valid_targets": [ "self" ], + "difficulty": 1, + "spell_class": "HEDGE_MAGIC", + "skill": "survival", + "effect": "spawn_item", + "effect_str": "item_invisibility_magic_square", + "shape": "blast", + "components": "spell_components_hedge_magic_square_twelve_hours", + "max_level": 1, + "min_damage": 1, + "max_damage": 1, + "base_casting_time": 4320000 } ]