Skip to content

Commit

Permalink
[Aftershock] Add the Geist (telekinetic) esper profession and powers (#…
Browse files Browse the repository at this point in the history
…79013)

* Initial commit

* Delete unused file

* Add Momentum Alteration

* Add Wave of Force

* Add professions

* Add Mindhammer

* Add practice recipes

* Add missing WONDER flag

* Linting

* Are you complaining about the profession translator's note?

* Power use fixes

* Fix meditating

* Change practice group name

---------

Co-authored-by: Anton Simakov <[email protected]>
  • Loading branch information
Standing-Storm and GuardianDll authored Jan 9, 2025
1 parent 5e1277a commit 42e255b
Show file tree
Hide file tree
Showing 15 changed files with 938 additions and 4 deletions.
1 change: 1 addition & 0 deletions data/mods/Aftershock/EOC/esper_eoc.json
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@
"EOC_AFS_ELECTROKIN_REMOVE_SEE_ELECTRICITY",
"EOC_AFS_ELECTROKIN_REMOVE_HACKING_INTERFACE",
"EOC_AFS_ELECTROKIN_REMOVE_PERSONAL_BATTERY",
"EOC_AFS_TELEKIN_REMOVE_MOMENTUM",
"EOC_AFS_TELEPATH_REMOVE_TELEPATHIC_SHIELD",
"EOC_AFS_TELEPATH_REMOVE_SENSE_MINDS",
"EOC_AFS_TELEPATH_REMOVE_TELEPATHIC_SUGGESTION"
Expand Down
55 changes: 55 additions & 0 deletions data/mods/Aftershock/EOC/esper_recipe_learning_eoc.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,61 @@
},
"effect": [ { "u_learn_recipe": "practice_afs_electrokinetic_recharge_vehicle" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_TELEKINETIC_RECIPE_TEACHER",
"eoc_type": "EVENT",
"required_event": "game_begin",
"condition": { "u_has_trait": "AFS_TELEKINETIC" },
"effect": [ { "run_eocs": "EOC_TEACH_AFS_TELEKINETIC_CONTEMPLATE_RECIPES" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_TEACH_AFS_TELEKINETIC_CONTEMPLATE_RECIPES",
"effect": [
{
"run_eocs": [
"EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MOVE_ITEM",
"EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MOVE_CREATURE",
"EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MOMENTUM",
"EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_WAVE_OF_FORCE",
"EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MINDHAMMER"
]
}
]
},
{
"type": "effect_on_condition",
"id": "EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MOVE_ITEM",
"condition": { "and": [ { "u_has_trait": "AFS_TELEKINETIC" }, { "math": [ "u_spell_level('afs_telekinetic_move_item') >= 0" ] } ] },
"effect": [ { "u_learn_recipe": "practice_afs_telekinetic_move_items" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MOVE_CREATURE",
"condition": {
"and": [ { "u_has_trait": "AFS_TELEKINETIC" }, { "math": [ "u_spell_level('afs_telekinetic_move_creature') >= 0" ] } ]
},
"effect": [ { "u_learn_recipe": "practice_afs_telekinetic_move_creatures" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MOMENTUM",
"condition": { "and": [ { "u_has_trait": "AFS_TELEKINETIC" }, { "math": [ "u_spell_level('afs_telekinetic_momentum') >= 0" ] } ] },
"effect": [ { "u_learn_recipe": "practice_afs_telekinetic_momentum" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_WAVE_OF_FORCE",
"condition": { "and": [ { "u_has_trait": "AFS_TELEKINETIC" }, { "math": [ "u_spell_level('afs_telekinetic_wave') >= 0" ] } ] },
"effect": [ { "u_learn_recipe": "practice_afs_telekinetic_wave" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_CHECK_GAMEBEGIN_AFS_TELEKINETIC_RECIPE_MINDHAMMER",
"condition": { "and": [ { "u_has_trait": "AFS_TELEKINETIC" }, { "math": [ "u_spell_level('afs_telekinetic_hammer') >= 0" ] } ] },
"effect": [ { "u_learn_recipe": "practice_afs_telekinetic_hammer" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_TELEPATH_RECIPE_TEACHER",
Expand Down
34 changes: 34 additions & 0 deletions data/mods/Aftershock/damage_types.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,40 @@
"melee_combat_info": { "order": 401, "show_type": false },
"ablative_info": { "order": 301, "show_type": false }
},
{
"id": "psi_telekinetic_damage",
"type": "damage_type",
"physical": false,
"magic_color": "yellow",
"name": "telekinetic",
"skill": "metaphysics",
"derived_from": [ "bash", 0.9 ],
"immune_flags": { "character": [ "TELEKIN_SHIELD" ], "monster": [ "TELEKIN_IMMUNE" ] },
"ondamage_eocs": [ "EOC_TELEKINETIC_DAMAGE_KNOCKDOWN_CHANCE", "EOC_TELEKINETIC_DAMAGE_STAGGER_CHANCE" ]
},
{
"type": "effect_on_condition",
"id": "EOC_TELEKINETIC_DAMAGE_STAGGER_CHANCE",
"condition": { "and": [ { "x_in_y_chance": { "x": { "math": [ "2" ] }, "y": 5 } }, { "math": [ "_damage_taken > 0" ] } ] },
"effect": [ { "npc_add_effect": "staggered", "duration": "2 s" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_TELEKINETIC_DAMAGE_KNOCKDOWN_CHANCE",
"condition": { "and": [ { "x_in_y_chance": { "x": { "math": [ "1" ] }, "y": 5 } }, { "math": [ "_damage_taken > 0" ] } ] },
"effect": [ { "npc_add_effect": "downed", "duration": "1 s" } ]
},
{
"id": "psi_telekinetic_damage",
"type": "damage_info_order",
"info_display": "detailed",
"verb": "buffeting",
"bionic_info": { "order": 999899, "show_type": false },
"protection_info": { "order": 999899, "show_type": false },
"pet_prot_info": { "order": 999899, "show_type": false },
"melee_combat_info": { "order": 999899, "show_type": false },
"ablative_info": { "order": 999899, "show_type": false }
},
{
"id": "psi_telepathic_damage",
"type": "damage_type",
Expand Down
59 changes: 56 additions & 3 deletions data/mods/Aftershock/effects_esper.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
[
{
"type": "effect_type",
"id": "effect_afs_esper_studying_power",
"//": "Hidden effect, used as a tracker",
"name": [ "" ],
"desc": [ "" ],
"rating": "good"
},
{
"type": "effect_type",
"id": "effect_afs_esper_headache",
Expand Down Expand Up @@ -93,9 +101,7 @@
{
"condition": { "test_eoc": "EOC_IS_ELECTRIC" },
"distance": {
"math": [
"( ( u_spell_level('electrokinesis_see_electric') * 1.5) + 6 ) * (scaling_factor(u_val('intelligence') ) ) * u_nether_attunement_power_scaling"
]
"math": [ "( ( u_spell_level('electrokinesis_see_electric') * 1.5) + 6 ) * (scaling_factor(u_val('intelligence') ) )" ]
},
"descriptions": [
{
Expand Down Expand Up @@ -146,6 +152,53 @@
"rating": "good",
"max_duration": "7 days"
},
{
"type": "effect_type",
"id": "effect_afs_telekinetic_momentum",
"name": [ "Altered Momentum" ],
"desc": [ "Your powers are affecting movement around you; dangerous objects are slowed and your own speed is increased." ],
"apply_message": "",
"remove_message": "Nearby movement returns to normal.",
"rating": "good",
"max_duration": "7 days",
"enchantments": [
{
"incoming_damage_mod": [
{
"type": "bash",
"multiply": { "math": [ "( u_spell_level('afs_telekinetic_momentum') * -0.01 ) * scaling_factor(u_val('intelligence') )" ] }
},
{
"type": "stab",
"multiply": { "math": [ "( u_spell_level('afs_telekinetic_momentum') * -0.005 ) * scaling_factor(u_val('intelligence') )" ] }
},
{
"type": "cut",
"multiply": { "math": [ "( u_spell_level('afs_telekinetic_momentum') * -0.005 ) * scaling_factor(u_val('intelligence') ) " ] }
},
{
"type": "bullet",
"multiply": { "math": [ "( u_spell_level('afs_telekinetic_momentum') * -0.02 ) * scaling_factor(u_val('intelligence') )" ] }
}
],
"values": [
{
"value": "MOVE_COST",
"multiply": {
"math": [
"max( ( ( ( u_spell_level('afs_telekinetic_momentum') * -0.005 ) * scaling_factor(u_val('intelligence') ) ) ), -0.15)"
]
}
},
{
"value": "ATTACK_SPEED",
"multiply": { "math": [ "( u_spell_level('afs_telekinetic_momentum') * -0.01 ) * scaling_factor(u_val('intelligence') )" ] }
}
]
}
],
"flags": [ "MUSCLE_VEH_BOOST" ]
},
{
"type": "effect_type",
"id": "effect_telepath_sense_minds",
Expand Down
10 changes: 10 additions & 0 deletions data/mods/Aftershock/flags.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,16 @@
"type": "json_flag",
"info": "You are immune to telepathy."
},
{
"id": "TELEKIN_SHIELD",
"type": "json_flag",
"//": "Immune to telekinetic damage"
},
{
"id": "TELEKIN_IMMUNE",
"type": "monster_flag",
"//": "Immune to telekinetic damage"
},
{
"id": "SHIELD_GENERATOR",
"type": "json_flag",
Expand Down
13 changes: 13 additions & 0 deletions data/mods/Aftershock/mutations/esper.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,19 @@
"player_display": false,
"spells_learned": [ [ "afs_classless_toggleable_concentration_end", 1 ] ]
},
{
"type": "mutation",
"id": "AFS_TELEKINETIC",
"name": "Telekinetic",
"points": 0,
"description": "The ability to move objects without touching them.",
"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",
Expand Down
11 changes: 11 additions & 0 deletions data/mods/Aftershock/player/activities.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[
{
"id": "ACT_AFS_ESPER_STUDYING_POWER",
"type": "activity_type",
"activity_level": "LIGHT_EXERCISE",
"verb": "meditating",
"based_on": "time",
"rooted": true,
"do_turn_eoc": "EOC_AFS_ESPER_STUDYING_POWER"
}
]
10 changes: 10 additions & 0 deletions data/mods/Aftershock/player/hobbies.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,15 @@
"points": 5,
"traits": [ "ESPER", "AFS_TELEPATH" ],
"spells": [ { "id": "afs_telepathic_mind_sense", "level": 3 }, { "id": "afs_telepathic_shield", "level": 2 } ]
},
{
"type": "profession",
"subtype": "hobby",
"id": "afs_telekinetic_hobby",
"name": "Esper Inheritance (Geist)",
"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_TELEKINETIC" ],
"spells": [ { "id": "afs_telekinetic_move_item", "level": 3 }, { "id": "afs_telekinetic_move_creature", "level": 2 } ]
}
]
36 changes: 36 additions & 0 deletions data/mods/Aftershock/player/professions.json
Original file line number Diff line number Diff line change
Expand Up @@ -704,5 +704,41 @@
"male": { "entries": [ { "item": "briefs" } ] },
"female": { "entries": [ { "item": "sports_bra" }, { "item": "boy_shorts" } ] }
}
},
{
"type": "profession",
"id": "afs_esper_telekinetic",
"name": "Geist",
"description": "You are a telekinetic, able to move objects without touching them. 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_TELEKINETIC" ],
"flags": [ "SCEN_ONLY" ],
"skills": [ { "level": 4, "name": "metaphysics" } ],
"spells": [
{ "id": "afs_telekinetic_move_item", "level": 8 },
{ "id": "afs_telekinetic_move_creature", "level": 6 },
{ "id": "afs_telekinetic_momentum", "level": 6 },
{ "id": "afs_telekinetic_wave", "level": 5 },
{ "id": "afs_telekinetic_hammer", "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" } ] }
}
}
]
97 changes: 97 additions & 0 deletions data/mods/Aftershock/recipes/esper/practice_eocs.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
[
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_STUDYING_POWER",
"condition": { "u_has_effect": "effect_afs_esper_studying_power" },
"effect": [
{ "math": [ "u_afs_esper_studying_tick_experience_counter", "+=", "contemplation_factor(1)" ] },
{
"if": { "math": [ "u_afs_esper_studying_tick_experience_counter >= 1" ] },
"then": [
{ "math": [ "u_spell_exp(u_latest_studied_power_name)", "+=", "1" ] },
{ "math": [ "u_afs_esper_studying_tick_experience_counter", "-=", "1" ] }
]
}
]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_STUDYING_POWER_BEGIN",
"condition": { "not": { "u_has_any_effect": [ "weary_5", "weary_6", "weary_7", "weary_8" ] } },
"effect": [
{ "u_message": "You spend some time meditating and developing your powers.", "type": "good" },
{ "math": [ "u_afs_esper_studying_tick_experience_counter = 0" ] },
{ "u_add_effect": "effect_afs_esper_studying_power", "duration": "24 hours" },
{ "u_assign_activity": "ACT_AFS_ESPER_STUDYING_POWER", "duration": "24 hours" },
{ "run_eocs": "EOC_AFS_ESPER_STUDYING_POWER_METAPHYSICS_GAIN", "time_in_future": [ "30 seconds", "5 minutes" ] }
],
"false_effect": [ { "u_message": "You are too exhausted to develop your powers.", "type": "bad" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_STUDYING_POWER_METAPHYSICS_GAIN",
"condition": {
"and": [
{ "u_has_effect": "effect_afs_esper_studying_power" },
{ "math": [ "u_latest_studied_power_difficulty > u_skill('metaphysics')" ] }
]
},
"effect": [
{ "math": [ "u_skill_exp('metaphysics', 'format': 'raw')", "+=", "(35 * u_latest_studied_power_difficulty)" ] },
{ "run_eocs": "EOC_AFS_ESPER_STUDYING_POWER_METAPHYSICS_GAIN", "time_in_future": [ "30 seconds", "5 minutes" ] }
]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_STUDYING_POWER_SIDE_EFFECTS",
"effect": [ { "run_eocs": "EOC_AFS_ESPER_STUDYING_POWER_FOCUS_REDUCTION", "time_in_future": [ "1 minutes", "1 minutes" ] } ]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_STUDYING_POWER_FOCUS_REDUCTION",
"condition": { "u_has_effect": "effect_afs_esper_studying_power" },
"effect": [
{ "if": { "math": [ "u_val('focus') >= 25" ] }, "then": { "math": [ "u_val('focus')", "-=", "rand(1)" ] } },
{ "run_eocs": "EOC_AFS_ESPER_STUDYING_POWER_FOCUS_REDUCTION", "time_in_future": [ "1 minutes", "1 minutes" ] }
]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_CANCELLING_ACTIVITY_CANCELS_RESEARCH",
"eoc_type": "EVENT",
"required_event": "character_finished_activity",
"condition": {
"and": [
{ "compare_string": [ "ACT_AFS_ESPER_STUDYING_POWER", { "context_val": "activity" } ] },
{ "u_has_effect": "effect_afs_esper_studying_power" }
]
},
"effect": [ { "u_lose_effect": "effect_afs_esper_studying_power" } ]
},
{
"type": "effect_on_condition",
"id": "EOC_AFS_ESPER_TOO_TIRED_TO_STUDY",
"eoc_type": "EVENT",
"required_event": "character_gains_effect",
"condition": {
"and": [
{
"or": [
{ "compare_string": [ "weary_5", { "context_val": "effect" } ] },
{ "compare_string": [ "weary_6", { "context_val": "effect" } ] },
{ "compare_string": [ "weary_7", { "context_val": "effect" } ] },
{ "compare_string": [ "weary_8", { "context_val": "effect" } ] }
]
},
{ "u_has_effect": "effect_afs_esper_studying_power" }
]
},
"effect": [
{ "u_lose_effect": "effect_afs_esper_studying_power" },
{
"u_message": "You're so exhausted you can barely think straight, and certainly can't concentrate on studying your powers.",
"popup": true
}
]
}
]
Loading

0 comments on commit 42e255b

Please sign in to comment.