Skip to content

Commit

Permalink
[MoM] Add Electrokinesis path (CleverRaven#69691)
Browse files Browse the repository at this point in the history
* Initial commit

* Add EMP immunity

* Update src/explosion.cpp

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update src/explosion.cpp

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Distribute electrokinetic matrix crystals into itemgroups

* Fixes

* Fix Galvanic Aura and Revivification

* Fix effects, add power learn ladder

* Kick tests

* Fix spelling

* Spelling

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
Standing-Storm and github-actions[bot] authored Nov 26, 2023
1 parent bdaa430 commit 6f1b1db
Show file tree
Hide file tree
Showing 21 changed files with 2,083 additions and 36 deletions.
5 changes: 5 additions & 0 deletions data/json/flags.json
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,11 @@
"type": "json_flag",
"info": "This gear <good>completely protects</good> you from <info>bash damage</info>."
},
{
"id": "EMP_IMMUNE",
"type": "json_flag",
"info": "This gear <good>completely protects</good> you from <info>EMP blasts</info>."
},
{
"id": "CUT_IMMUNE",
"type": "json_flag",
Expand Down
175 changes: 151 additions & 24 deletions data/mods/MindOverMatter/effectoncondition/eoc_awakening.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@
{ "u_spawn_item": "matrix_crystal_drained", "suppress_message": true }
]
},
{
"type": "effect_on_condition",
"id": "EOC_ELECTRO_CRYSTAL_DRAINING",
"condition": { "u_has_item": "matrix_crystal_electrokinesis" },
"effect": [
{ "u_consume_item": "matrix_crystal_electrokinesis", "count": 1 },
{ "u_spawn_item": "matrix_crystal_drained", "suppress_message": true }
]
},
{
"type": "effect_on_condition",
"id": "EOC_PHOTOKIN_CRYSTAL_DRAINING",
Expand Down
18 changes: 18 additions & 0 deletions data/mods/MindOverMatter/effectoncondition/eoc_learn_recipes.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,24 @@
{ "u_learn_recipe": "practice_clair_omniscience" }
]
},
{
"type": "effect_on_condition",
"id": "EOC_TEACH_ELECTROKIN_CONTEMPLATE_RECIPES",
"effect": [
{ "u_learn_recipe": "practice_electrokinetic_see_electric" },
{ "u_learn_recipe": "practice_electrokinetic_shock_touch" },
{ "u_learn_recipe": "practice_electrokinetic_zap_enemies" },
{ "u_learn_recipe": "practice_electrokinetic_melee_attacks" },
{ "u_learn_recipe": "practice_electrokinetic_personal_battery" },
{ "u_learn_recipe": "practice_electrokinetic_paralysis" },
{ "u_learn_recipe": "practice_electrokinetic_lightning_bolt" },
{ "u_learn_recipe": "practice_electrokinetic_speed_boost" },
{ "u_learn_recipe": "practice_electrokinetic_kill_robot" },
{ "u_learn_recipe": "practice_electrokinetic_lightning_aura" },
{ "u_learn_recipe": "practice_electrokinetic_lightning_blast" },
{ "u_learn_recipe": "practice_electrokinetic_revive" }
]
},
{
"type": "effect_on_condition",
"id": "EOC_TEACH_PHOTOKIN_CONTEMPLATE_RECIPES",
Expand Down
16 changes: 16 additions & 0 deletions data/mods/MindOverMatter/effectoncondition/eoc_power_effects.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,22 @@
"condition": { "and": [ { "u_has_trait": "CLAIRSENTIENT" }, { "u_has_wielded_with_flag": "MATRIX_CRYSTAL_CLAIRSENTIENCE" } ] },
"effect": [ { "math": [ "u_val('spell_level_adjustment', 'school: CLAIRSENTIENT')", "=", "4" ] } ]
},
{
"type": "effect_on_condition",
"id": "EOC_ELECTRO_MATRIX_BOOST",
"eoc_type": "EVENT",
"required_event": "opens_spellbook",
"condition": { "and": [ { "u_has_trait": "ELECTROKINETIC" }, { "u_has_wielded_with_flag": "MATRIX_CRYSTAL_ELECTROKINESIS" } ] },
"effect": [ { "math": [ "u_val('spell_level_adjustment', 'school: ELECTROKINETIC')", "=", "4" ] } ]
},
{
"type": "effect_on_condition",
"id": "EOC_PHOTO_MATRIX_BOOST",
"eoc_type": "EVENT",
"required_event": "opens_spellbook",
"condition": { "and": [ { "u_has_trait": "PHOTOKINETIC" }, { "u_has_wielded_with_flag": "MATRIX_CRYSTAL_PHOTOKINESIS" } ] },
"effect": [ { "math": [ "u_val('spell_level_adjustment', 'school: PHOTOKINETIC')", "=", "4" ] } ]
},
{
"type": "effect_on_condition",
"id": "EOC_PYRO_MATRIX_BOOST",
Expand Down
37 changes: 37 additions & 0 deletions data/mods/MindOverMatter/effects/effects_monster.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,43 @@
"base_mods": { "rad_amount": [ 2 ], "rad_min": [ 3, 1 ] },
"immune_flags": [ "RAD_PROOF", "NO_RADIATION" ]
},
{
"type": "effect_type",
"id": "effect_electrokin_revive_debuff",
"name": [
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified",
"Revivified"
],
"desc": [ "Causes the target to eventually die. It's a bug if you have it." ],
"max_intensity": 12,
"int_decay_step": 1,
"int_decay_tick": 60,
"show_in_info": true,
"chance_kill": [
[ 1, 200000 ],
[ 1, 100000 ],
[ 1, 50000 ],
[ 1, 10000 ],
[ 1, 5000 ],
[ 1, 1000 ],
[ 1, 500 ],
[ 1, 100 ],
[ 1, 50 ],
[ 1, 20 ],
[ 1, 5 ],
[ 1, 1 ]
]
},
{
"type": "effect_type",
"id": "effect_photokinetic_illumination",
Expand Down
128 changes: 128 additions & 0 deletions data/mods/MindOverMatter/effects/effects_psionic.json
Original file line number Diff line number Diff line change
Expand Up @@ -595,6 +595,7 @@
"apply_message": "",
"rating": "bad",
"max_duration": "1 minutes",
"show_in_info": true,
"enchantments": [
{
"values": [
Expand Down Expand Up @@ -776,6 +777,133 @@
"flags": [ "SUPER_CLAIRVOYANCE" ],
"vitamins": [ { "vitamin": "vitamin_psionic_drain", "rate": [ [ 1, 1 ] ], "tick": [ "2 s" ] } ]
},
{
"type": "effect_type",
"id": "effect_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.",
"decay_messages": [ [ "You can only see an occasional flicker of charge.", "bad" ], [ "Your electrical senses are fading.", "bad" ] ],
"rating": "good",
"max_duration": "45 minutes",
"max_intensity": 83,
"dur_add_perc": 10,
"int_dur_factor": "32 s",
"enchantments": [
{
"values": [
{
"value": "SIGHT_RANGE_ELECTRIC",
"add": {
"math": [
"( ( u_val('spell_level', 'spell: electrokinesis_see_electric') * 1.5) + 6 ) * (scaling_factor(u_val('intelligence') ) )"
]
}
}
]
}
]
},
{
"type": "effect_type",
"id": "effect_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_electrokin_zap_enemies" ],
"flags": [ "EMP_IMMUNE" ]
},
{
"type": "effect_type",
"id": "effect_electrokin_melee_attacks",
"name": [ "Voltaic Strikes" ],
"desc": [ "Your melee attacks unleash electrical blasts." ],
"apply_message": "",
"remove_message": "Your hands no longer spark with electricity.",
"decay_messages": [ [ "The charge in your hands is nearly gone.", "bad" ], [ "The current in your hands is fading.", "bad" ] ],
"rating": "good",
"max_duration": "20 minutes",
"max_intensity": 73,
"dur_add_perc": 10,
"int_dur_factor": "17 s",
"enchantments": [ "enchant_electrokin_electric_strikes" ]
},
{
"type": "effect_type",
"id": "effect_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_electrokinetic_speed_boost",
"name": [ "Neuro-Accelerated" ],
"desc": [ "You are enhancing your nervous system." ],
"apply_message": "",
"remove_message": "Your reactions return to baseline.",
"decay_messages": [
[ "Your enhanced reactions are nearly gone.", "bad" ],
[ "Your reaction times are gradually becoming slower.", "bad" ]
],
"rating": "good",
"max_duration": "30 minutes",
"max_intensity": 61,
"dur_add_perc": 10,
"int_dur_factor": "29 s",
"enchantments": [
{
"values": [
{
"value": "LEARNING_FOCUS",
"add": {
"math": [
"min( ( 5 + u_val('spell_level', 'spell: electrokinetic_speed_boost') ) * ( ( u_val('intelligence') + 10) / 20 ), 35 )"
]
}
},
{
"value": "SPEED",
"add": {
"math": [
"min( ( 10 + ( ( u_val('spell_level', 'spell: electrokinetic_speed_boost') ) * 1.5) ) * ( ( u_val('intelligence') + 10) / 20 ), 60 )"
]
}
}
]
}
]
},
{
"type": "effect_type",
"id": "effect_electrokinetic_lightning_aura",
"name": [ "Galvanic Aura" ],
"desc": [ "Anyone nearby risks being blasted by lightning." ],
"apply_message": "",
"remove_message": "The thrum in the air around you dissipates.",
"decay_messages": [
[ "The crackling aura around you is fading quickly.", "bad" ],
[ "The lightning blasts are growing less powerful.", "bad" ]
],
"rating": "good",
"max_duration": "10 minutes",
"max_intensity": 36,
"dur_add_perc": 10,
"int_dur_factor": "17 s",
"enchantments": [ "enchant_electrokin_lightning_aura" ],
"flags": [ "EMP_IMMUNE" ]
},
{
"type": "effect_type",
"id": "effect_photokin_light_local",
Expand Down
Loading

0 comments on commit 6f1b1db

Please sign in to comment.