diff --git a/data/mods/Aftershock/EOC/_reusable_conditions.json b/data/mods/Aftershock/EOC/_reusable_conditions.json index dd33338c215c1..72a997e1f6881 100644 --- a/data/mods/Aftershock/EOC/_reusable_conditions.json +++ b/data/mods/Aftershock/EOC/_reusable_conditions.json @@ -2,7 +2,20 @@ "type": "effect_on_condition", "id": "EOC_CONDITION_can_hack", "condition": { - "and": [ { "u_has_item": "electrohack" }, "u_can_see" ] + "and": [ + { + "or": [ + { "u_has_item": "electrohack" }, + { "u_has_item": "electrokinetic_electrohack_1" }, + { "u_has_item": "electrokinetic_electrohack_2" }, + { "u_has_item": "electrokinetic_electrohack_3" }, + { "u_has_item": "electrokinetic_electrohack_4" }, + { "u_has_item": "electrokinetic_electrohack_5" }, + { "u_has_item": "electrokinetic_electrohack_6" } + ] + }, + "u_can_see" + ] }, "effect": [ diff --git a/data/mods/Aftershock/EOC/esper_eoc.json b/data/mods/Aftershock/EOC/esper_eoc.json index 10da1776d4b2d..ac5e437ff2deb 100644 --- a/data/mods/Aftershock/EOC/esper_eoc.json +++ b/data/mods/Aftershock/EOC/esper_eoc.json @@ -106,6 +106,9 @@ "effect": [ { "run_eocs": [ + "EOC_AFS_ELECTROKIN_REMOVE_SEE_ELECTRICITY", + "EOC_AFS_ELECTROKIN_REMOVE_HACKING_INTERFACE", + "EOC_AFS_ELECTROKIN_REMOVE_PERSONAL_BATTERY", "EOC_AFS_TELEPATH_REMOVE_TELEPATHIC_SHIELD", "EOC_AFS_TELEPATH_REMOVE_SENSE_MINDS", "EOC_AFS_TELEPATH_REMOVE_TELEPATHIC_SUGGESTION" @@ -262,6 +265,14 @@ }, "effect": [ { "run_eocs": [ "EOC_AFS_END_PSI_POWERS_MAINTAINED" ] } ] }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ESPER_WINDED_ENDS_POWERS", + "eoc_type": "EVENT", + "required_event": "character_gains_effect", + "condition": { "or": [ { "compare_string": [ "winded", { "context_val": "effect" } ] } ] }, + "effect": [ { "run_eocs": [ "EOC_AFS_END_PSI_POWERS_MAINTAINED" ] } ] + }, { "type": "effect_on_condition", "id": "EOC_AFS_ESPER_STUNNED_ENDS_POWERS", diff --git a/data/mods/Aftershock/EOC/esper_recipe_learning_eoc.json b/data/mods/Aftershock/EOC/esper_recipe_learning_eoc.json index 2fff8a3d0ef8d..7487126f0a18c 100644 --- a/data/mods/Aftershock/EOC/esper_recipe_learning_eoc.json +++ b/data/mods/Aftershock/EOC/esper_recipe_learning_eoc.json @@ -1,4 +1,94 @@ [ + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKINETIC_RECIPE_TEACHER", + "eoc_type": "EVENT", + "required_event": "game_begin", + "condition": { "u_has_trait": "AFS_ELECTROKINETIC" }, + "effect": [ { "run_eocs": "EOC_TEACH_AFS_ELECTROKINETIC_CONTEMPLATE_RECIPES" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_TEACH_AFS_ELECTROKINETIC_CONTEMPLATE_RECIPES", + "effect": [ + { + "run_eocs": [ + "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_SEE_ELECTRIC", + "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_SHOCK_TOUCH", + "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_ZAP_ENEMIES", + "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_HACKING_INTERFACE", + "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_PERSONAL_BATTERY", + "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_RECHARGE_VEHICLE" + ] + } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_SEE_ELECTRIC", + "condition": { + "and": [ + { "u_has_trait": "AFS_ELECTROKINETIC" }, + { "math": [ "u_spell_level('afs_electrokinetic_see_electric')", ">=", "0" ] } + ] + }, + "effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_see_electric" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_SHOCK_TOUCH", + "condition": { + "and": [ + { "u_has_trait": "AFS_ELECTROKINETIC" }, + { "math": [ "u_spell_level('afs_electrokinetic_shock_touch')", ">=", "0" ] } + ] + }, + "effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_shock_touch" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_ZAP_ENEMIES", + "condition": { + "and": [ + { "u_has_trait": "AFS_ELECTROKINETIC" }, + { "math": [ "u_spell_level('afs_electrokinetic_zap_enemies')", ">=", "0" ] } + ] + }, + "effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_zap_enemies" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_HACKING_INTERFACE", + "condition": { + "and": [ + { "u_has_trait": "AFS_ELECTROKINETIC" }, + { "math": [ "u_spell_level('afs_electrokinetic_hacking_interface')", ">=", "0" ] } + ] + }, + "effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_hacking_interface" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_PERSONAL_BATTERY", + "condition": { + "and": [ + { "u_has_trait": "AFS_ELECTROKINETIC" }, + { "math": [ "u_spell_level('afs_electrokinetic_personal_battery')", ">=", "0" ] } + ] + }, + "effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_personal_battery" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_CHECK_GAMEBEGIN_AFS_ELECTROKIN_RECIPE_RECHARGE_VEHICLE", + "condition": { + "and": [ + { "u_has_trait": "AFS_ELECTROKINETIC" }, + { "math": [ "u_spell_level('afs_electrokinetic_recharge_vehicle')", ">=", "0" ] } + ] + }, + "effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_recharge_vehicle" } ] + }, { "type": "effect_on_condition", "id": "EOC_AFS_TELEPATH_RECIPE_TEACHER", diff --git a/data/mods/Aftershock/effects_esper.json b/data/mods/Aftershock/effects_esper.json index 90eae1b8f5f6d..6f861c70d8f93 100644 --- a/data/mods/Aftershock/effects_esper.json +++ b/data/mods/Aftershock/effects_esper.json @@ -77,6 +77,66 @@ "immune_flags": [ "TEEPSHIELD", "TEEP_IMMUNE" ], "flags": [ "DISABLE_FLIGHT", "EFFECT_LIMB_SCORE_MOD", "NO_SPELLCASTING", "NO_PSIONICS" ] }, + { + "type": "effect_type", + "id": "effect_afs_electrokin_see_electricity", + "name": [ "Spark Sight" ], + "desc": [ "Your powers reveal electrical creatures and robots to you." ], + "apply_message": "", + "remove_message": "You can no longer sense the flow of current.", + "rating": "good", + "max_duration": "7 days", + "enchantments": [ + { + "values": [ + { + "value": "SIGHT_RANGE_ELECTRIC", + "add": { + "math": [ + "( ( u_spell_level('electrokinesis_see_electric') * 1.5) + 6 ) * (scaling_factor(u_val('intelligence') ) ) * u_nether_attunement_power_scaling" + ] + } + } + ] + } + ] + }, + { + "type": "effect_type", + "id": "effect_afs_electrokin_zap_enemies", + "name": [ "Electrical Discharge" ], + "desc": [ "Your body is filled with electrical currents." ], + "apply_message": "", + "remove_message": "The tingling on your skin fades.", + "decay_messages": [ [ "The protective electrical currents are nearly gone.", "bad" ], [ "Your skin is losing its charge.", "bad" ] ], + "rating": "good", + "max_duration": "20 minutes", + "max_intensity": 49, + "dur_add_perc": 10, + "int_dur_factor": "25 s", + "enchantments": [ "enchant_afs_electrokin_zap_enemies" ], + "flags": [ "EMP_IMMUNE" ] + }, + { + "type": "effect_type", + "id": "effect_afs_electrokin_hacking_interface", + "name": [ "Hacking Interface" ], + "desc": [ "You are capable of hacking into computers with only the power of your mind." ], + "apply_message": "", + "remove_message": "You can no longer manipulate the circuitry of nearby devices.", + "rating": "good", + "max_duration": "7 days" + }, + { + "type": "effect_type", + "id": "effect_afs_electrokin_personal_battery", + "name": [ "Electron Overflow" ], + "desc": [ "You are generating a wireless aura of electrical power." ], + "apply_message": "", + "remove_message": "You stop the flow of electricity to your devices.", + "rating": "good", + "max_duration": "7 days" + }, { "type": "effect_type", "id": "effect_telepath_sense_minds", diff --git a/data/mods/Aftershock/items/esper_summons.json b/data/mods/Aftershock/items/esper_summons.json new file mode 100644 index 0000000000000..24c98b7b5d914 --- /dev/null +++ b/data/mods/Aftershock/items/esper_summons.json @@ -0,0 +1,140 @@ +[ + { + "id": "electrokinetic_electrohack_1", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]hacking interface" }, + "description": "You can hack nearby devices.", + "weight": "0 g", + "volume": "0 ml", + "symbol": "=", + "color": "cyan", + "looks_like": "spiral_stone", + "flags": [ + "TRADER_AVOID", + "ONLY_ONE", + "NO_DROP", + "PADDED", + "PERSONAL", + "UNBREAKABLE", + "SEMITANGIBLE", + "NO_SALVAGE", + "ZERO_WEIGHT", + "NO_UNLOAD", + "NO_RELOAD", + "INTEGRATED", + "MAGICAL" + ], + "qualities": [ [ "HACK", 0 ] ] + }, + { + "id": "electrokinetic_electrohack_2", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]hacking interface" }, + "description": "You can hack nearby devices.", + "copy-from": "electrokinetic_electrohack_1", + "qualities": [ [ "HACK", 1 ] ] + }, + { + "id": "electrokinetic_electrohack_3", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]hacking interface" }, + "description": "You can hack nearby devices.", + "copy-from": "electrokinetic_electrohack_1", + "qualities": [ [ "HACK", 2 ] ] + }, + { + "id": "electrokinetic_electrohack_4", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]hacking interface" }, + "description": "You can hack nearby devices.", + "copy-from": "electrokinetic_electrohack_1", + "qualities": [ [ "HACK", 3 ] ] + }, + { + "id": "electrokinetic_electrohack_5", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]hacking interface" }, + "description": "You can hack nearby devices.", + "copy-from": "electrokinetic_electrohack_1", + "qualities": [ [ "HACK", 4 ] ] + }, + { + "id": "afs_electrokinetic_ups_1", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]electron overflow" }, + "description": "You are generating power for your personal devices.", + "weight": "0 g", + "volume": "0 ml", + "symbol": "=", + "color": "cyan", + "looks_like": "spiral_stone", + "flags": [ + "TRADER_AVOID", + "ONLY_ONE", + "NO_DROP", + "PADDED", + "PERSONAL", + "UNBREAKABLE", + "SEMITANGIBLE", + "INTEGRATED", + "NO_SALVAGE", + "ZERO_WEIGHT", + "NO_UNLOAD", + "NO_RELOAD", + "IS_UPS" + ], + "pocket_data": [ { "pocket_type": "MAGAZINE", "rigid": true, "ammo_restriction": { "battery": 400 } } ], + "relic_data": { "charge_info": { "recharge_type": "periodic", "time": "2 s", "regenerate_ammo": true } }, + "//": "Recharge time is 2 seconds due to bug #48019, making it actually 1 second. Reduce to 1 second if that ever gets fixed." + }, + { + "id": "afs_electrokinetic_ups_2", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]electron overflow" }, + "description": "You are generating power for your personal devices.", + "copy-from": "afs_electrokinetic_ups_1", + "pocket_data": [ { "pocket_type": "MAGAZINE", "rigid": true, "ammo_restriction": { "battery": 800 } } ], + "relic_data": { "charge_info": { "recharge_type": "periodic", "time": "2 s", "regenerate_ammo": true } }, + "//": "Recharge time is 2 seconds due to bug #48019, making it actually 1 second. Reduce to 1 second if that ever gets fixed." + }, + { + "id": "afs_electrokinetic_ups_3", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]electron overflow" }, + "description": "You are generating power for your personal devices.", + "copy-from": "afs_electrokinetic_ups_1", + "pocket_data": [ { "pocket_type": "MAGAZINE", "rigid": true, "ammo_restriction": { "battery": 1500 } } ], + "relic_data": { "charge_info": { "recharge_type": "periodic", "time": "2 s", "regenerate_ammo": true } }, + "//": "Recharge time is 2 seconds due to bug #48019, making it actually 1 second. Reduce to 1 second if that ever gets fixed." + }, + { + "id": "afs_electrokinetic_ups_4", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]electron overflow" }, + "description": "You are generating power for your personal devices.", + "copy-from": "afs_electrokinetic_ups_1", + "pocket_data": [ { "pocket_type": "MAGAZINE", "rigid": true, "ammo_restriction": { "battery": 2500 } } ], + "relic_data": { "charge_info": { "recharge_type": "periodic", "time": "2 s", "regenerate_ammo": true } }, + "//": "Recharge time is 2 seconds due to bug #48019, making it actually 1 second. Reduce to 1 second if that ever gets fixed." + }, + { + "id": "afs_electrokinetic_ups_5", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]electron overflow" }, + "description": "You are generating power for your personal devices.", + "copy-from": "afs_electrokinetic_ups_1", + "pocket_data": [ { "pocket_type": "MAGAZINE", "rigid": true, "ammo_restriction": { "battery": 5000 } } ], + "relic_data": { "charge_info": { "recharge_type": "periodic", "time": "2 s", "regenerate_ammo": true } }, + "//": "Recharge time is 2 seconds due to bug #48019, making it actually 1 second. Reduce to 1 second if that ever gets fixed." + }, + { + "id": "afs_electrokinetic_ups_6", + "type": "TOOL_ARMOR", + "name": { "str": "[Ψ]electron overflow" }, + "description": "You are generating power for your personal devices.", + "copy-from": "afs_electrokinetic_ups_1", + "pocket_data": [ { "pocket_type": "MAGAZINE", "rigid": true, "ammo_restriction": { "battery": 10000 } } ], + "relic_data": { "charge_info": { "recharge_type": "periodic", "time": "2 s", "regenerate_ammo": true } }, + "//": "Recharge time is 2 seconds due to bug #48019, making it actually 1 second. Reduce to 1 second if that ever gets fixed." + } +] diff --git a/data/mods/Aftershock/mutations/esper.json b/data/mods/Aftershock/mutations/esper.json index f1bf588eb01a1..b3dbf025eb3bc 100644 --- a/data/mods/Aftershock/mutations/esper.json +++ b/data/mods/Aftershock/mutations/esper.json @@ -13,6 +13,19 @@ "purifiable": false, "valid": false }, + { + "type": "mutation", + "id": "AFS_ELECTROKINETIC", + "name": "Electrokinetic", + "points": 0, + "description": "The ability to to control electricity with your mind.", + "types": [ "ESPER" ], + "starting_trait": false, + "purifiable": false, + "valid": false, + "player_display": false, + "spells_learned": [ [ "afs_classless_toggleable_concentration_end", 1 ] ] + }, { "type": "mutation", "id": "AFS_TELEPATH", diff --git a/data/mods/Aftershock/player/hobbies.json b/data/mods/Aftershock/player/hobbies.json index 747c034ec9339..b0694d84fb09a 100644 --- a/data/mods/Aftershock/player/hobbies.json +++ b/data/mods/Aftershock/player/hobbies.json @@ -45,13 +45,23 @@ "points": 3, "traits": [ "AFS_LEADERSHIP" ] }, + { + "type": "profession", + "subtype": "hobby", + "id": "afs_electrokinetic_hobby", + "name": "Esper Inheritance (Spark)", + "description": "Some long-distant member of your family received psi treatments during the Hyperspace Era and somehow it stuck in their DNA. Always unpredictable, skipping multiple generations at a time, that inheritance has been passed down to you. You have no training and little idea what you're doing, but you've developed a trick or two.", + "points": 5, + "traits": [ "ESPER", "AFS_ELECTROKINETIC" ], + "spells": [ { "id": "afs_electrokinetic_see_electric", "level": 3 }, { "id": "afs_electrokinetic_shock_touch", "level": 2 } ] + }, { "type": "profession", "subtype": "hobby", "id": "afs_telepath_hobby", "name": "Esper Inheritance (Whisper)", "description": "Some long-distant member of your family received psi treatments during the Hyperspace Era and somehow it stuck in their DNA. Always unpredictable, skipping multiple generations at a time, that inheritance has been passed down to you. You have no training and little idea what you're doing, but you've developed a trick or two.", - "points": 3, + "points": 5, "traits": [ "ESPER", "AFS_TELEPATH" ], "spells": [ { "id": "afs_telepathic_mind_sense", "level": 3 }, { "id": "afs_telepathic_shield", "level": 2 } ] } diff --git a/data/mods/Aftershock/player/professions.json b/data/mods/Aftershock/player/professions.json index 6ab6712b93a2f..0815b4d89340a 100644 --- a/data/mods/Aftershock/player/professions.json +++ b/data/mods/Aftershock/player/professions.json @@ -671,5 +671,41 @@ "male": { "entries": [ { "item": "briefs" } ] }, "female": { "entries": [ { "item": "sports_bra" }, { "item": "boy_shorts" } ] } } + }, + { + "type": "profession", + "id": "afs_esper_electrokinetic", + "name": "Spark", + "description": "You are an electrokinetic, able to control electricity with your mind. You aren't entirely sure how you got your powers, but you seem to have an instinctive sense of how to use them. That's not sinister at all, right?", + "points": 7, + "traits": [ "AFS_ELECTROKINETIC" ], + "flags": [ "SCEN_ONLY" ], + "skills": [ { "level": 4, "name": "metaphysics" } ], + "spells": [ + { "id": "afs_electrokinetic_see_electric", "level": 8 }, + { "id": "afs_electrokinetic_zap_enemies", "level": 6 }, + { "id": "afs_electrokinetic_hacking_interface", "level": 6 }, + { "id": "afs_electrokinetic_personal_battery", "level": 5 }, + { "id": "afs_electrokinetic_recharge_vehicle", "level": 3 } + ], + "proficiencies": [ "prof_concentration_basic" ], + "items": { + "both": { + "entries": [ + { "item": "spacer_jumpsuit" }, + { "item": "spacer_cap" }, + { "item": "socks" }, + { "item": "boots" }, + { "item": "wristwatch" }, + { "item": "cream_prot_cold" }, + { "item": "cream_prot_cold" }, + { "group": "charged_smart_phone" }, + { "item": "XL_holster" }, + { "item": "afs_cartridge", "ammo-item": "battery", "charges": [ 900, 1485 ], "container-item": "afs_v29" } + ] + }, + "male": { "entries": [ { "item": "briefs" } ] }, + "female": { "entries": [ { "item": "sports_bra" }, { "item": "boy_shorts" } ] } + } } ] diff --git a/data/mods/Aftershock/recipes/esper/electrokinesis_practice.json b/data/mods/Aftershock/recipes/esper/electrokinesis_practice.json new file mode 100644 index 0000000000000..ca6f6cd7bd920 --- /dev/null +++ b/data/mods/Aftershock/recipes/esper/electrokinesis_practice.json @@ -0,0 +1,189 @@ +[ + { + "id": "afs_electrokinesis_practice", + "type": "nested_category", + "activity_level": "LIGHT_EXERCISE", + "category": "CC_PRACTICE", + "subcategory": "CSC_PRACTICE_PSI", + "name": "[Ψ]practice: electrokinesis", + "description": "Recipes related to practicing electrokinesis.", + "skill_used": "metaphysics", + "nested_category_data": [ + "practice_afs_electrokinetic_see_electric", + "practice_afs_electrokinetic_shock_touch", + "practice_afs_electrokinetic_zap_enemies", + "practice_afs_electrokinetic_hacking_interface", + "practice_afs_electrokinetic_personal_battery", + "practice_afs_electrokinetic_recharge_vehicle" + ], + "difficulty": 1 + }, + { + "type": "recipe", + "activity_level": "LIGHT_EXERCISE", + "name": "[Ψ]spark sight", + "id": "practice_afs_electrokinetic_see_electric", + "description": "Contemplate your powers and improve your ability to detect electrical creatures or robots.", + "category": "CC_*", + "subcategory": "CSC_*_NESTED", + "skill_used": "metaphysics", + "difficulty": 1, + "time": "30 m", + "autolearn": false, + "flags": [ "SECRET", "BLIND_EASY", "NO_MANIP", "AFFECTED_BY_PAIN", "NO_BENCH", "NO_ENCHANTMENT" ], + "result_eocs": [ + { + "id": "EOC_PRACTICE_AFS_ELECTROKIN_SPARK_SIGHT", + "condition": { "math": [ "u_spell_level('afs_electrokinetic_see_electric')", ">=", "1" ] }, + "effect": [ + { + "u_message": "You spend some time meditating and contemplating your powers and emerge with new knowledge.", + "type": "good" + }, + { "math": [ "u_spell_exp('afs_electrokinetic_see_electric')", "+=", "(contemplation_factor(1))" ] }, + { "run_eocs": "EOC_AFS_PSI_PRACTICE_FOCUS_MOD" } + ] + } + ] + }, + { + "type": "recipe", + "activity_level": "LIGHT_EXERCISE", + "name": "[Ψ]static touch", + "id": "practice_afs_electrokinetic_shock_touch", + "description": "Contemplate your powers and improve your ability to build up a charge in your hand and unleash it.", + "category": "CC_*", + "subcategory": "CSC_*_NESTED", + "skill_used": "metaphysics", + "difficulty": 0, + "time": "30 m", + "autolearn": false, + "flags": [ "SECRET", "BLIND_EASY", "NO_MANIP", "AFFECTED_BY_PAIN", "NO_BENCH", "NO_ENCHANTMENT" ], + "result_eocs": [ + { + "id": "EOC_PRACTICE_AFS_ELECTROKIN_SHOCK_TOUCH", + "condition": { "math": [ "u_spell_level('electrokinetic_shock_touch')", ">=", "1" ] }, + "effect": [ + { + "u_message": "You spend some time meditating and contemplating your powers and emerge with new knowledge.", + "type": "good" + }, + { "math": [ "u_spell_exp('electrokinetic_shock_touch')", "+=", "(contemplation_factor(1))" ] }, + { "run_eocs": "EOC_AFS_PSI_PRACTICE_FOCUS_MOD" } + ] + } + ] + }, + { + "type": "recipe", + "activity_level": "LIGHT_EXERCISE", + "name": "[Ψ]electrical discharge", + "id": "practice_afs_electrokinetic_zap_enemies", + "description": "Contemplate your powers and improve your ability to electrocute those who attack you in melee.", + "category": "CC_*", + "subcategory": "CSC_*_NESTED", + "skill_used": "metaphysics", + "difficulty": 2, + "time": "30 m", + "autolearn": false, + "flags": [ "SECRET", "BLIND_EASY", "NO_MANIP", "AFFECTED_BY_PAIN", "NO_BENCH", "NO_ENCHANTMENT" ], + "result_eocs": [ + { + "id": "EOC_PRACTICE_AFS_ELECTROKIN_ZAP_ENEMIES", + "condition": { "math": [ "u_spell_level('afs_electrokinetic_zap_enemies')", ">=", "1" ] }, + "effect": [ + { + "u_message": "You spend some time meditating and contemplating your powers and emerge with new knowledge.", + "type": "good" + }, + { "math": [ "u_spell_exp('afs_electrokinetic_zap_enemies')", "+=", "(contemplation_factor(1))" ] }, + { "run_eocs": "EOC_AFS_PSI_PRACTICE_FOCUS_MOD" } + ] + } + ] + }, + { + "type": "recipe", + "activity_level": "LIGHT_EXERCISE", + "name": "[Ψ]hacking interface", + "id": "practice_afs_electrokinetic_hacking_interface", + "description": "Contemplate your powers and improve your ability to hack nearby devices with your powers.", + "category": "CC_*", + "subcategory": "CSC_*_NESTED", + "skill_used": "metaphysics", + "difficulty": 3, + "time": "30 m", + "autolearn": false, + "flags": [ "SECRET", "BLIND_EASY", "NO_MANIP", "AFFECTED_BY_PAIN", "NO_BENCH", "NO_ENCHANTMENT" ], + "result_eocs": [ + { + "id": "EOC_PRACTICE_AFS_ELECTRO_HACKING_INTERFACE", + "condition": { "math": [ "u_spell_level('afs_electrokinetic_hacking_interface')", ">=", "1" ] }, + "effect": [ + { + "u_message": "You spend some time meditating and contemplating your powers and emerge with new knowledge.", + "type": "good" + }, + { "math": [ "u_spell_exp('afs_electrokinetic_hacking_interface')", "+=", "(contemplation_factor(1))" ] }, + { "run_eocs": "EOC_AFS_PSI_PRACTICE_FOCUS_MOD" } + ] + } + ] + }, + { + "type": "recipe", + "activity_level": "LIGHT_EXERCISE", + "name": "[Ψ]electron overflow", + "id": "practice_afs_electrokinetic_personal_battery", + "description": "Contemplate your powers and improve your ability to fuel personal electronic devices with your powers.", + "category": "CC_*", + "subcategory": "CSC_*_NESTED", + "skill_used": "metaphysics", + "difficulty": 4, + "time": "30 m", + "autolearn": false, + "flags": [ "SECRET", "BLIND_EASY", "NO_MANIP", "AFFECTED_BY_PAIN", "NO_BENCH", "NO_ENCHANTMENT" ], + "result_eocs": [ + { + "id": "EOC_PRACTICE_AFS_ELECTRO_PERSONAL_BATTERY", + "condition": { "math": [ "u_spell_level('afs_electrokinetic_personal_battery')", ">=", "1" ] }, + "effect": [ + { + "u_message": "You spend some time meditating and contemplating your powers and emerge with new knowledge.", + "type": "good" + }, + { "math": [ "u_spell_exp('afs_electrokinetic_personal_battery')", "+=", "(contemplation_factor(1))" ] }, + { "run_eocs": "EOC_AFS_PSI_PRACTICE_FOCUS_MOD" } + ] + } + ] + }, + { + "type": "recipe", + "activity_level": "LIGHT_EXERCISE", + "name": "[Ψ]re-energize", + "id": "practice_afs_electrokinetic_recharge_vehicle", + "description": "Contemplate your powers and improve your ability to recharge large-scale batteries or connected power grids.", + "category": "CC_*", + "subcategory": "CSC_*_NESTED", + "skill_used": "metaphysics", + "difficulty": 7, + "time": "30 m", + "autolearn": false, + "flags": [ "SECRET", "BLIND_EASY", "NO_MANIP", "AFFECTED_BY_PAIN", "NO_BENCH", "NO_ENCHANTMENT" ], + "result_eocs": [ + { + "id": "EOC_PRACTICE_AFS_ELECTROKIN_RECHARGE_VEHICLE", + "condition": { "math": [ "u_spell_level('afs_electrokinetic_recharge_vehicle')", ">=", "1" ] }, + "effect": [ + { + "u_message": "You spend some time meditating and contemplating your powers and emerge with new knowledge.", + "type": "good" + }, + { "math": [ "u_spell_exp('afs_electrokinetic_recharge_vehicle')", "+=", "(contemplation_factor(1))" ] }, + { "run_eocs": "EOC_AFS_PSI_PRACTICE_FOCUS_MOD" } + ] + } + ] + } +] diff --git a/data/mods/Aftershock/scenarios.json b/data/mods/Aftershock/scenarios.json index 9f4e25e996e83..b3ad9794eb5b2 100644 --- a/data/mods/Aftershock/scenarios.json +++ b/data/mods/Aftershock/scenarios.json @@ -216,9 +216,10 @@ "description": "There are stories that before the Discontinuity, scientists had developed treatments to unlock the powers of the human mind. To read thoughts, move objects at a distance, control computers by the power of will alone, and even stranger things. Just one more lost secret of the Golden Age.\n\nOr so you thought, but recently you had heard some tantalizing rumors about espers, centered on a backwater planet on the edge of known civilization. You remember buying passage to the Salus system, arriving at Port Augustmoon and buying supplies, and descending to the surface, and after that…things get hazy. You're not entirely sure where you are, and you've clearly been through it, but somehow you've rediscovered that lost secret. Now you just need to make it back alive.", "forced_traits": [ "ESPER" ], "allowed_locs": [ "sloc_afs_glacial_tunnels" ], - "professions": [ "afs_esper_telepath" ], + "professions": [ "afs_esper_electrokinetic", "afs_esper_telepath" ], "flags": [ "LONE_START" ], "start_name": "Lost on the Surface", + "reveal_locale": false, "eoc": [ "EOC_ESPER_SCENARIO_SETUP" ] } ] diff --git a/data/mods/Aftershock/spells/psionics/electrokinesis.json b/data/mods/Aftershock/spells/psionics/electrokinesis.json new file mode 100644 index 0000000000000..a40c7e26a2059 --- /dev/null +++ b/data/mods/Aftershock/spells/psionics/electrokinesis.json @@ -0,0 +1,205 @@ +[ + { + "id": "afs_electrokinetic_see_electric", + "type": "SPELL", + "name": "[Ψ]Spark Sight (C)", + "description": "Open your senses to the flow of electricity, revealing nearby electrical creatures or robots.\n\nThis power is maintained by concentration and may fail if concentration is interrupted.", + "message": "", + "teachable": false, + "valid_targets": [ "self" ], + "spell_class": "AFS_ELECTROKINETIC", + "skill": "metaphysics", + "flags": [ "PSIONIC", "CONCENTRATE", "SILENT", "NO_HANDS", "NO_LEGS", "NO_EXPLOSION_SFX", "RANDOM_DURATION" ], + "difficulty": 2, + "max_level": { "math": [ "int_to_level(1)" ] }, + "effect": "effect_on_condition", + "effect_str": "EOC_AFS_ELECTROKIN_SEE_ELECTRICITY_INITIATE", + "shape": "blast", + "min_duration": { + "math": [ "( (u_spell_level('afs_electrokinetic_see_electric') * 15000) + 90000) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "max_duration": { + "math": [ "( (u_spell_level('afs_electrokinetic_see_electric') * 30000) + 180000) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "energy_source": "STAMINA", + "base_energy_cost": { + "math": [ + "u_effect_intensity('effect_electrokin_see_electricity') > -1 ? 0 : max((2000 - (u_spell_level('afs_electrokinetic_see_electric') * 75)), 750)" + ] + }, + "base_casting_time": { + "math": [ + "u_effect_intensity('effect_electrokin_see_electricity') > -1 ? 10 : max((150 -(u_spell_level('afs_electrokinetic_see_electric') * 6)), 80)" + ] + } + }, + { + "id": "afs_electrokinetic_shock_touch", + "type": "SPELL", + "name": "[Ψ]Static Touch", + "description": "Unleash a shock when touching a target, doing a small amount of damage and dazing them.", + "message": "Your hands crackle with sparks!", + "teachable": false, + "valid_targets": [ "hostile", "ground", "ally" ], + "spell_class": "AFS_ELECTROKINETIC", + "skill": "metaphysics", + "flags": [ "PSIONIC", "CONCENTRATE", "LOUD", "NO_PROJECTILE", "RANDOM_DAMAGE", "RANDOM_DURATION", "NO_HANDS", "NO_LEGS" ], + "difficulty": 1, + "max_level": { "math": [ "int_to_level(1)" ] }, + "effect": "attack", + "effect_str": "psi_dazed_zap", + "shape": "blast", + "damage_type": "electric", + "min_damage": { + "math": [ "( (u_spell_level('afs_electrokinetic_shock_touch') * 1) + 2) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "max_damage": { + "math": [ "( (u_spell_level('afs_electrokinetic_shock_touch') * 1.5) + 7) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "min_range": 1, + "max_range": 1, + "min_duration": 100, + "max_duration": 300, + "field_id": "fd_electricity", + "min_field_intensity": 1, + "max_field_intensity": 2, + "field_chance": 1, + "energy_source": "STAMINA", + "base_energy_cost": 1500, + "final_energy_cost": 450, + "energy_increment": -65, + "base_casting_time": 100, + "final_casting_time": 35, + "casting_time_increment": -4, + "sound_type": "combat", + "sound_description": "zzzaaaaapp!", + "ignored_monster_species": [ "PSI_NULL" ] + }, + { + "id": "afs_electrokinetic_zap_enemies", + "type": "SPELL", + "name": "[Ψ]Electrical Discharge", + "description": "Build up a charge in your body, zapping anyone who attempts to attack you in melee. It will also protect you from EMP attacks.", + "message": "Your skin tingles.", + "teachable": false, + "valid_targets": [ "self" ], + "spell_class": "AFS_ELECTROKINETIC", + "skill": "metaphysics", + "flags": [ "PSIONIC", "CONCENTRATE", "SILENT", "NO_HANDS", "NO_LEGS", "NO_EXPLOSION_SFX", "RANDOM_DURATION" ], + "difficulty": 3, + "max_level": { "math": [ "int_to_level(1)" ] }, + "effect": "attack", + "effect_str": "effect_afs_electrokin_zap_enemies", + "shape": "blast", + "min_duration": { + "math": [ "( (u_spell_level('afs_electrokinetic_zap_enemies') * 8000) + 30000) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "max_duration": { + "math": [ "( (u_spell_level('afs_electrokinetic_zap_enemies') * 22500) + 80000) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "energy_source": "STAMINA", + "base_energy_cost": 3500, + "final_energy_cost": 1100, + "energy_increment": -120, + "base_casting_time": 125, + "final_casting_time": 45, + "casting_time_increment": -5 + }, + { + "id": "afs_electrokinetic_hacking_interface", + "type": "SPELL", + "name": "[Ψ]Hacking Interface (C)", + "description": "Create an electrical interface with your powers, allowing you to hack nearby devices as if you were using a computer.\n\nThis power is maintained by concentration and may fail if concentration is interrupted.", + "message": "", + "teachable": false, + "valid_targets": [ "self" ], + "spell_class": "AFS_ELECTROKINETIC", + "skill": "metaphysics", + "flags": [ "PSIONIC", "CONCENTRATE", "SILENT", "NO_HANDS", "NO_LEGS", "NO_EXPLOSION_SFX", "RANDOM_DURATION" ], + "difficulty": 4, + "max_level": { "math": [ "int_to_level(1)" ] }, + "effect": "effect_on_condition", + "effect_str": "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_INITIATE", + "shape": "blast", + "min_duration": { + "math": [ + "( ( (u_spell_level('afs_electrokinetic_hacking_interface') * 4500 ) + 60000) * (scaling_factor(u_val('intelligence') ) ) )" + ] + }, + "max_duration": { + "math": [ + "( ( (u_spell_level('afs_electrokinetic_hacking_interface') * 9000 ) + 180000) * (scaling_factor(u_val('intelligence') ) ) )" + ] + }, + "energy_source": "STAMINA", + "base_energy_cost": { + "math": [ + "u_effect_intensity('effect_electrokin_hacking_interface') > 0 ? 0 : max((6500 - (u_spell_level('afs_electrokinetic_hacking_interface') * 150)), 3500)" + ] + }, + "base_casting_time": { + "math": [ + "u_effect_intensity('effect_electrokin_hacking_interface') > 0 ? 10 : max((350 -(u_spell_level('afs_electrokinetic_hacking_interface') * 9)), 150)" + ] + } + }, + { + "id": "afs_electrokinetic_personal_battery", + "type": "SPELL", + "name": "[Ψ]Electron Overflow (C)", + "description": "Generate power for UPS compatible devices on your person.\n\nThis power is maintained by concentration and may fail if concentration is interrupted.", + "message": "", + "teachable": false, + "valid_targets": [ "self" ], + "spell_class": "AFS_ELECTROKINETIC", + "skill": "metaphysics", + "flags": [ "PSIONIC", "CONCENTRATE", "SILENT", "NO_HANDS", "NO_LEGS", "NO_EXPLOSION_SFX", "RANDOM_DURATION" ], + "difficulty": 5, + "max_level": { "math": [ "int_to_level(1)" ] }, + "effect": "effect_on_condition", + "effect_str": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_INITIATE", + "shape": "blast", + "min_damage": 1, + "min_duration": 120000, + "max_duration": 360000, + "energy_source": "STAMINA", + "base_energy_cost": { + "math": [ + "u_effect_intensity('effect_electrokin_personal_battery') > 0 ? 0 : max((6500 - (u_spell_level('afs_electrokinetic_personal_battery') * 150)), 3500)" + ] + }, + "base_casting_time": { + "math": [ + "u_effect_intensity('effect_electrokin_personal_battery') > 0 ? 10 : max((350 -(u_spell_level('afs_electrokinetic_personal_battery') * 9)), 150)" + ] + } + }, + { + "id": "afs_electrokinetic_recharge_vehicle", + "type": "SPELL", + "name": "[Ψ]Re-energize", + "description": "Turn your own energy into power for a vehicle or appliance. You need merely touch the vehicle or any part of the power grid to recharge the batteries.", + "message": "Power flows into your target.", + "teachable": false, + "valid_targets": [ "ground" ], + "spell_class": "AFS_ELECTROKINETIC", + "skill": "metaphysics", + "flags": [ "PSIONIC", "CONCENTRATE", "SILENT", "NO_HANDS", "NO_LEGS", "NO_EXPLOSION_SFX", "RANDOM_DAMAGE" ], + "difficulty": 8, + "max_level": { "math": [ "int_to_level(1)" ] }, + "effect": "recharge_vehicle", + "shape": "blast", + "min_damage": { + "math": [ "( (u_spell_level('afs_electrokinetic_recharge_vehicle') * 125) + 250) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "max_damage": { + "math": [ "( (u_spell_level('afs_electrokinetic_recharge_vehicle') * 250) + 500) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "min_range": 1, + "energy_source": "STAMINA", + "base_energy_cost": 7500, + "final_energy_cost": 4500, + "energy_increment": -150, + "base_casting_time": 1500 + } +] diff --git a/data/mods/Aftershock/spells/psionics/electrokinesis_concentration_eocs.json b/data/mods/Aftershock/spells/psionics/electrokinesis_concentration_eocs.json new file mode 100644 index 0000000000000..f9cc6711ff5f2 --- /dev/null +++ b/data/mods/Aftershock/spells/psionics/electrokinesis_concentration_eocs.json @@ -0,0 +1,271 @@ +[ + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_SEE_ELECTRICITY_INITIATE", + "condition": { "not": { "u_has_effect": "effect_afs_electrokin_see_electricity" } }, + "effect": [ + { "u_message": "You open your senses to the flow of current.", "type": "good" }, + { "run_eocs": "EOC_AFS_POWER_MAINTENANCE_PLUS_ONE" }, + { "u_add_effect": "effect_afs_electrokin_see_electricity", "duration": "PERMANENT" }, + { + "queue_eocs": "EOC_AFS_ELECTROKIN_SEE_ELECTRICITY_MAINTENANCE", + "time_in_future": [ + { + "math": [ "( (u_spell_level('afs_electrokinetic_see_electric') * 150) + 900) * (scaling_factor(u_val('intelligence') ) )" ] + }, + { + "math": [ "( (u_spell_level('afs_electrokinetic_see_electric') * 300) + 1800) * (scaling_factor(u_val('intelligence') ) )" ] + } + ] + } + ], + "false_effect": [ { "run_eocs": "EOC_AFS_ELECTROKIN_REMOVE_SEE_ELECTRICITY" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_REMOVE_SEE_ELECTRICITY", + "condition": { "u_has_effect": "effect_afs_electrokin_see_electricity" }, + "effect": [ { "run_eocs": "EOC_AFS_POWER_MAINTENANCE_MINUS_ONE" }, { "u_lose_effect": "effect_afs_electrokin_see_electricity" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_SEE_ELECTRICITY_MAINTENANCE", + "condition": { "u_has_effect": "effect_afs_electrokin_see_electricity" }, + "effect": [ + { "math": [ "u_latest_channeled_power_difficulty", "=", "2" ] }, + { + "math": [ "u_spell_exp('afs_electrokinetic_see_electric')", "+=", "(maintenance_exp_factor(u_val('focus')))" ] + }, + { + "run_eocs": [ + "EOC_CONCENTRATION_SUCCESS_PROFICIENCY", + "EOC_AFS_PSI_SKILL_INCREASE_ON_USE_FINALIZE", + "EOC_AFS_CONCENTRATION_COSTS_FOCUS" + ] + }, + { + "queue_eocs": "EOC_AFS_ELECTROKIN_SEE_ELECTRICITY_MAINTENANCE", + "time_in_future": [ + { + "math": [ "( (u_spell_level('afs_electrokinetic_see_electric') * 150) + 900) * (scaling_factor(u_val('intelligence') ) )" ] + }, + { + "math": [ "( (u_spell_level('afs_electrokinetic_see_electric') * 300) + 1800) * (scaling_factor(u_val('intelligence') ) )" ] + } + ] + } + ], + "false_effect": [ ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_INITIATE", + "condition": { "not": { "u_has_effect": "effect_afs_electrokin_hacking_interface" } }, + "effect": [ + { "u_message": "You now have the ability to hack into nearby electronics.", "type": "good" }, + { "run_eocs": [ "EOC_AFS_POWER_MAINTENANCE_MINUS_ONE", "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_SWITCHER" ] }, + { "u_add_effect": "effect_afs_electrokin_hacking_interface", "duration": "PERMANENT" }, + { + "queue_eocs": "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_MAINTENANCE", + "time_in_future": [ + { + "math": [ + "( ( (u_spell_level('afs_electrokinetic_hacking_interface') * 45 ) + 600) * (scaling_factor(u_val('intelligence') ) ) )" + ] + }, + { + "math": [ + "( ( (u_spell_level('afs_electrokinetic_hacking_interface') * 90 ) + 1800) * (scaling_factor(u_val('intelligence') ) ) )" + ] + } + ] + } + ], + "false_effect": [ { "run_eocs": "EOC_AFS_ELECTROKIN_REMOVE_HACKING_INTERFACE" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_REMOVE_HACKING_INTERFACE", + "condition": { "u_has_effect": "effect_afs_electrokin_hacking_interface" }, + "effect": [ + { "u_remove_item_with": "electrokinetic_electrohack_1" }, + { "u_remove_item_with": "electrokinetic_electrohack_2" }, + { "u_remove_item_with": "electrokinetic_electrohack_3" }, + { "u_remove_item_with": "electrokinetic_electrohack_4" }, + { "u_remove_item_with": "electrokinetic_electrohack_5" }, + { "u_lose_effect": "effect_afs_electrokin_hacking_interface" }, + { "run_eocs": "EOC_AFS_POWER_MAINTENANCE_MINUS_ONE" } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_SWITCHER", + "effect": { + "switch": { "math": [ "u_spell_level('afs_electrokinetic_hacking_interface')" ] }, + "cases": [ + { + "case": 0, + "effect": [ { "u_spawn_item": "electrokinetic_electrohack_1", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 5, + "effect": [ { "u_spawn_item": "electrokinetic_electrohack_2", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 10, + "effect": [ { "u_spawn_item": "electrokinetic_electrohack_3", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 15, + "effect": [ { "u_spawn_item": "electrokinetic_electrohack_4", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 20, + "effect": [ { "u_spawn_item": "electrokinetic_electrohack_5", "suppress_message": true, "force_equip": true } ] + } + ] + } + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_MAINTENANCE", + "condition": { "u_has_effect": "effect_afs_electrokin_hacking_interface" }, + "effect": [ + { "math": [ "u_latest_channeled_power_difficulty", "=", "4" ] }, + { + "math": [ "u_spell_exp('afs_electrokinetic_hacking_interface')", "+=", "(maintenance_exp_factor(u_val('focus')))" ] + }, + { + "run_eocs": [ + "EOC_CONCENTRATION_SUCCESS_PROFICIENCY", + "EOC_AFS_PSI_SKILL_INCREASE_ON_USE_FINALIZE", + "EOC_AFS_CONCENTRATION_COSTS_FOCUS" + ] + }, + { + "queue_eocs": "EOC_AFS_ELECTROKIN_HACKING_INTERFACE_MAINTENANCE", + "time_in_future": [ + { + "math": [ + "( ( (u_spell_level('afs_electrokinetic_hacking_interface') * 45 ) + 600) * (scaling_factor(u_val('intelligence') ) ) )" + ] + }, + { + "math": [ + "( ( (u_spell_level('afs_electrokinetic_hacking_interface') * 90 ) + 1800) * (scaling_factor(u_val('intelligence') ) ) )" + ] + } + ] + } + ], + "false_effect": [ ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_INITIATE", + "condition": { "not": { "u_has_effect": "effect_afs_electrokin_personal_battery" } }, + "effect": [ + { "u_message": "The hair on your body stands up on end.", "type": "good" }, + { "run_eocs": [ "EOC_AFS_POWER_MAINTENANCE_MINUS_ONE", "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_SWITCHER" ] }, + { "u_add_effect": "effect_afs_electrokin_personal_battery", "duration": "PERMANENT" }, + { + "queue_eocs": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_MAINTENANCE", + "time_in_future": [ + { + "math": [ + "min( (( ( (u_spell_level('afs_electrokinetic_personal_battery') * 45 ) + 600) * (scaling_factor(u_val('intelligence') ) ) )), 14400)" + ] + }, + { + "math": [ + "min( (( ( (u_spell_level('afs_electrokinetic_personal_battery') * 90 ) + 1800) * (scaling_factor(u_val('intelligence') ) ) )), 14400)" + ] + } + ] + } + ], + "false_effect": [ { "run_eocs": "EOC_AFS_ELECTROKIN_REMOVE_PERSONAL_BATTERY" } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_REMOVE_PERSONAL_BATTERY", + "condition": { "u_has_effect": "effect_afs_electrokin_personal_battery" }, + "effect": [ + { "u_remove_item_with": "afs_electrokinetic_ups_1" }, + { "u_remove_item_with": "afs_electrokinetic_ups_2" }, + { "u_remove_item_with": "afs_electrokinetic_ups_3" }, + { "u_remove_item_with": "afs_electrokinetic_ups_4" }, + { "u_remove_item_with": "afs_electrokinetic_ups_5" }, + { "u_remove_item_with": "afs_electrokinetic_ups_6" }, + { "u_lose_effect": "effect_afs_electrokin_personal_battery" }, + { "run_eocs": "EOC_AFS_POWER_MAINTENANCE_MINUS_ONE" } + ] + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_SWITCHER", + "effect": { + "switch": { "math": [ "u_spell_level('afs_electrokinetic_personal_battery')" ] }, + "cases": [ + { + "case": 0, + "effect": [ { "u_spawn_item": "afs_electrokinetic_ups_1", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 4, + "effect": [ { "u_spawn_item": "afs_electrokinetic_ups_2", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 8, + "effect": [ { "u_spawn_item": "afs_electrokinetic_ups_3", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 12, + "effect": [ { "u_spawn_item": "afs_electrokinetic_ups_4", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 16, + "effect": [ { "u_spawn_item": "afs_electrokinetic_ups_5", "suppress_message": true, "force_equip": true } ] + }, + { + "case": 20, + "effect": [ { "u_spawn_item": "afs_electrokinetic_ups_6", "suppress_message": true, "force_equip": true } ] + } + ] + } + }, + { + "type": "effect_on_condition", + "id": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_MAINTENANCE", + "condition": { "u_has_effect": "effect_afs_electrokin_personal_battery" }, + "effect": [ + { "math": [ "u_latest_channeled_power_difficulty", "=", "5" ] }, + { + "math": [ "u_spell_exp('afs_electrokinetic_personal_battery')", "+=", "(maintenance_exp_factor(u_val('focus')))" ] + }, + { + "run_eocs": [ + "EOC_CONCENTRATION_SUCCESS_PROFICIENCY", + "EOC_AFS_PSI_SKILL_INCREASE_ON_USE_FINALIZE", + "EOC_AFS_CONCENTRATION_COSTS_FOCUS" + ] + }, + { + "queue_eocs": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_MAINTENANCE", + "time_in_future": [ + { + "math": [ + "min( (( ( (u_spell_level('afs_electrokinetic_personal_battery') * 45 ) + 600) * (scaling_factor(u_val('intelligence') ) ) )), 14400)" + ] + }, + { + "math": [ + "min( (( ( (u_spell_level('afs_electrokinetic_personal_battery') * 90 ) + 1800) * (scaling_factor(u_val('intelligence') ) ) )), 14400)" + ] + } + ] + } + ], + "false_effect": [ ] + } +] diff --git a/data/mods/Aftershock/spells/psionics/enchantments.json b/data/mods/Aftershock/spells/psionics/enchantments.json new file mode 100644 index 0000000000000..e9d07601d712b --- /dev/null +++ b/data/mods/Aftershock/spells/psionics/enchantments.json @@ -0,0 +1,28 @@ +[ + { + "type": "enchantment", + "id": "enchant_afs_electrokin_zap_enemies", + "condition": "ALWAYS", + "has": "HELD", + "hit_me_effect": [ { "id": "afs_electrokin_zap_attacked", "hit_self": false, "once_in": 2 } ] + }, + { + "id": "afs_electrokin_zap_attacked", + "type": "SPELL", + "name": "Electrokinetic aura thorns", + "description": "Do electrical damage to a monster that attacked you. If you have this directly its a bug.", + "valid_targets": [ "hostile" ], + "flags": [ "RANDOM_DAMAGE" ], + "shape": "blast", + "effect": "attack", + "damage_type": "electric", + "min_damage": { + "math": [ "( (u_spell_level('afs_electrokinetic_zap_enemies') / 4 ) + 1) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "max_damage": { + "math": [ "( (u_spell_level('afs_electrokinetic_zap_enemies') / 2 ) + 5) * (scaling_factor(u_val('intelligence') ) )" ] + }, + "min_range": 1, + "max_range": 1 + } +]