Skip to content

Commit

Permalink
[MOM][Aftershock] Adds new 'uses_energy' search data and converts ele…
Browse files Browse the repository at this point in the history
…ctron overflow powers to use it (#77062)

* Add uses_energy filter for search data and convert the electron overflow powers to use that for searching.  Deletes old flag that used to be used for this.

* lint

* Update doc with suggestion

Co-authored-by: Anton Simakov <[email protected]>

* Switch to optional struct

* get rid of the exclamation mark

* Convert new eoc content to uses_energy

* fix aftershock missing a variable declaration

---------

Co-authored-by: Anton Simakov <[email protected]>
  • Loading branch information
b3brodie and GuardianDll authored Oct 18, 2024
1 parent 0764d84 commit d2943c9
Show file tree
Hide file tree
Showing 14 changed files with 37 additions and 234 deletions.
5 changes: 0 additions & 5 deletions data/mods/Aftershock/flags.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,5 @@
"id": "TEEP_IMMUNE",
"type": "monster_flag",
"//": "Immune to telepathic damage"
},
{
"id": "ELECTROKINETIC_CHARGEABLE",
"type": "json_flag",
"info": "This item can be recharged by an electrokinetic"
}
]
58 changes: 0 additions & 58 deletions data/mods/Aftershock/items/electrokinetic_charging_overrides.json

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -227,14 +227,10 @@
}
]
},
{ "math": [ "u_afs_electrokin_personal_battery_count", "=", "0" ] },
{
"u_run_inv_eocs": "all",
"search_data": [
{ "flags": [ "RECHARGE" ] },
{ "flags": [ "ELECTRONIC" ] },
{ "flags": [ "ELECTROKINETIC_CHARGEABLE" ] },
{ "flags": [ "USE_UPS" ] }
],
"search_data": [ { "uses_energy": true } ],
"true_eocs": [
{
"id": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_INV_SCANNER_COUNTER",
Expand All @@ -254,12 +250,7 @@
"effect": [
{
"u_run_inv_eocs": "all",
"search_data": [
{ "flags": [ "RECHARGE" ] },
{ "flags": [ "ELECTRONIC" ] },
{ "flags": [ "ELECTROKINETIC_CHARGEABLE" ] },
{ "flags": [ "USE_UPS" ] }
],
"search_data": [ { "uses_energy": true } ],
"true_eocs": [
{
"id": "EOC_AFS_ELECTROKIN_PERSONAL_BATTERY_INV_SCANNER_VALUE_ADDED",
Expand Down

This file was deleted.

5 changes: 0 additions & 5 deletions data/mods/MindOverMatter/json_flags.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@
"type": "json_flag",
"info": "You are protected against telepathic attack. Sometimes."
},
{
"id": "ELECTROKINETIC_CHARGEABLE",
"type": "json_flag",
"info": "This item can be recharged by an electrokinetic"
},
{
"id": "MATRIX_CRYSTAL_BIOKINESIS",
"type": "json_flag",
Expand Down
7 changes: 1 addition & 6 deletions data/mods/MindOverMatter/monsters/monster_eoc_spells.json
Original file line number Diff line number Diff line change
Expand Up @@ -289,12 +289,7 @@
"condition": { "not": { "u_has_effect": "effect_electrokin_personal_battery" } },
"effect": {
"u_run_inv_eocs": "random",
"search_data": [
{ "flags": [ "RECHARGE" ] },
{ "flags": [ "ELECTRONIC" ] },
{ "flags": [ "ELECTROKINETIC_CHARGEABLE" ] },
{ "flags": [ "USE_UPS" ] }
],
"search_data": [ { "uses_energy": true } ],
"true_eocs": [
{
"id": "EOC_ELECTRONKINETIC_MONSTER_POWER_DRAINING_INV_RESULT",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -329,12 +329,7 @@
{ "math": [ "u_electrokin_personal_battery_count", "=", "0" ] },
{
"u_run_inv_eocs": "all",
"search_data": [
{ "flags": [ "RECHARGE" ] },
{ "flags": [ "ELECTRONIC" ] },
{ "flags": [ "ELECTROKINETIC_CHARGEABLE" ] },
{ "flags": [ "USE_UPS" ] }
],
"search_data": [ { "uses_energy": true } ],
"true_eocs": [
{
"id": "EOC_ELECTROKIN_PERSONAL_BATTERY_INV_SCANNER_COUNTER",
Expand All @@ -354,12 +349,7 @@
"effect": [
{
"u_run_inv_eocs": "all",
"search_data": [
{ "flags": [ "RECHARGE" ] },
{ "flags": [ "ELECTRONIC" ] },
{ "flags": [ "ELECTROKINETIC_CHARGEABLE" ] },
{ "flags": [ "USE_UPS" ] }
],
"search_data": [ { "uses_energy": true } ],
"true_eocs": [
{
"id": "EOC_ELECTROKIN_PERSONAL_BATTERY_INV_SCANNER_VALUE_ADDED",
Expand Down
5 changes: 0 additions & 5 deletions data/mods/Xedra_Evolved/flags.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@
"type": "json_flag",
"info": "This gear will transform you into animal form, and may have some side effects."
},
{
"id": "ELECTROKINETIC_CHARGEABLE",
"type": "json_flag",
"info": "This item can be recharged by an electrokinetic"
},
{
"id": "HEDGE_ENCHANTED",
"type": "json_flag",
Expand Down
35 changes: 7 additions & 28 deletions data/mods/Xedra_Evolved/items/inventor/armor.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,17 +52,7 @@
}
],
"techniques": [ "WBLOCK_1" ],
"flags": [
"MORPHIC",
"WATERPROOF",
"STURDY",
"PADDED",
"TRADER_AVOID",
"PSYSHIELD_PARTIAL",
"MUNDANE",
"INVENTOR_CRAFTED",
"ELECTROKINETIC_CHARGEABLE"
]
"flags": [ "MORPHIC", "WATERPROOF", "STURDY", "PADDED", "TRADER_AVOID", "PSYSHIELD_PARTIAL", "MUNDANE", "INVENTOR_CRAFTED" ]
},
{
"id": "helmet_inventor_on",
Expand Down Expand Up @@ -175,7 +165,7 @@
"symbol": "[",
"looks_like": "legguard_hard",
"color": "light_red",
"flags": [ "MORPHIC", "STURDY", "OUTER", "BELTED", "MUNDANE", "INVENTOR_CRAFTED", "ELECTROKINETIC_CHARGEABLE" ],
"flags": [ "MORPHIC", "STURDY", "OUTER", "BELTED", "MUNDANE", "INVENTOR_CRAFTED" ],
"ammo": "battery",
"use_action": {
"target": "inventor_leg_weight_on",
Expand Down Expand Up @@ -237,7 +227,7 @@
"symbol": "[",
"looks_like": "legguard_hard",
"color": "light_red",
"flags": [ "MORPHIC", "STURDY", "OUTER", "SOFT", "MUNDANE", "INVENTOR_CRAFTED", "ELECTROKINETIC_CHARGEABLE" ],
"flags": [ "MORPHIC", "STURDY", "OUTER", "SOFT", "MUNDANE", "INVENTOR_CRAFTED" ],
"ammo": "battery",
"charges_per_use": 150,
"use_action": { "type": "cast_spell", "spell_id": "jump_boots_leap", "no_fail": true, "level": 0 },
Expand Down Expand Up @@ -349,17 +339,7 @@
}
],
"techniques": [ "WBLOCK_1" ],
"flags": [
"MORPHIC",
"WATERPROOF",
"STURDY",
"SOFT",
"TRADER_AVOID",
"BELTED",
"MUNDANE",
"INVENTOR_CRAFTED",
"ELECTROKINETIC_CHARGEABLE"
]
"flags": [ "MORPHIC", "WATERPROOF", "STURDY", "SOFT", "TRADER_AVOID", "BELTED", "MUNDANE", "INVENTOR_CRAFTED" ]
},
{
"id": "aura_force_on",
Expand Down Expand Up @@ -411,8 +391,7 @@
"CALORIES_INTAKE",
"ELECTRONIC",
"MUNDANE",
"INVENTOR_CRAFTED",
"ELECTROKINETIC_CHARGEABLE"
"INVENTOR_CRAFTED"
],
"pocket_data": [
{
Expand Down Expand Up @@ -560,7 +539,7 @@
"weight": "300 g",
"longest_side": "25 cm",
"ammo": [ "battery" ],
"flags": [ "MORPHIC", "ONLY_ONE", "TRADER_AVOID", "MUNDANE", "INVENTOR_CRAFTED", "ELECTROKINETIC_CHARGEABLE" ],
"flags": [ "MORPHIC", "ONLY_ONE", "TRADER_AVOID", "MUNDANE", "INVENTOR_CRAFTED" ],
"use_action": [
{
"target": "inventor_electric_fist_act",
Expand Down Expand Up @@ -623,7 +602,7 @@
"color": "dark_gray",
"material_thickness": 0.4,
"environmental_protection": 4,
"flags": [ "MORPHIC", "MUNDANE", "INVENTOR_CRAFTED", "ELECTROKINETIC_CHARGEABLE" ],
"flags": [ "MORPHIC", "MUNDANE", "INVENTOR_CRAFTED" ],
"relic_data": {
"passive_effects": [ { "has": "WORN", "condition": "ACTIVE", "values": [ { "value": "REGEN_STAMINA", "multiply": 0.6 } ] } ]
},
Expand Down
Loading

0 comments on commit d2943c9

Please sign in to comment.