diff --git a/data/json/effects_on_condition/bionic_active_eocs.json b/data/json/effects_on_condition/bionic_active_eocs.json index 49a2bac47eba8..9edc376667afa 100644 --- a/data/json/effects_on_condition/bionic_active_eocs.json +++ b/data/json/effects_on_condition/bionic_active_eocs.json @@ -76,9 +76,7 @@ "then": [ { "u_lose_effect": "meth" }, { "u_add_effect": "meth", "duration": "200 s" } ] }, { - "foreach": "array", - "var": { "context_val": "effect_id" }, - "target": [ + "u_lose_effect": [ "fungus", "dermatik", "bloodworms", @@ -107,8 +105,7 @@ "venom_weaken", "venom_dmg", "paralyzepoison" - ], - "effect": { "u_lose_effect": { "context_val": "effect_id" } } + ] }, { "math": [ "u_val('pkill') = 0" ] }, { "math": [ "u_val('stim') = 0" ] }, diff --git a/data/json/effects_on_condition/medicine_eocs/contant_lenses_eocs.json b/data/json/effects_on_condition/medicine_eocs/contant_lenses_eocs.json index 29e8d2939f512..f9eaa0766ac5e 100644 --- a/data/json/effects_on_condition/medicine_eocs/contant_lenses_eocs.json +++ b/data/json/effects_on_condition/medicine_eocs/contant_lenses_eocs.json @@ -53,9 +53,7 @@ "type": "effect_on_condition", "id": "EOC_CONTACTS3", "effect": [ - { "u_lose_effect": "contacts" }, - { "u_lose_effect": "transition_contacts" }, - { "u_lose_effect": "transition_contacts_plano" }, + { "u_lose_effect": [ "contacts", "transition_contacts", "transition_contacts_plano" ] }, { "u_add_effect": { "context_val": "effect" }, "duration": { "math": [ "rng(_time * 0.94, _time * 1.06)" ] } }, { "u_consume_item": { "context_val": "id" } } ] diff --git a/data/json/effects_on_condition/misc_effect_on_condition.json b/data/json/effects_on_condition/misc_effect_on_condition.json index 0313b746ed635..4d1b0cb810042 100644 --- a/data/json/effects_on_condition/misc_effect_on_condition.json +++ b/data/json/effects_on_condition/misc_effect_on_condition.json @@ -90,21 +90,16 @@ "condition": { "and": [ { "u_has_effect": "hallucination_attacks" }, { "x_in_y_chance": { "x": 1, "y": 6 } } ] }, "effect": [ { - "run_eocs": { - "id": "EOC_HALLUCINATION_ATTACKS", - "condition": { "math": [ "u_monsters_nearby() > 1" ] }, - "effect": [ - { - "u_spawn_monster": "GROUP_YOUR_FEARS", - "group": true, - "real_count": 0, - "hallucination_count": { "math": [ "rand(2) + 1" ] }, - "outdoor_only": false, - "min_radius": 10, - "max_radius": 40, - "lifespan": [ "1 hours", "4 hours" ] - } - ] + "if": { "math": [ "u_monsters_nearby() > 1" ] }, + "then": { + "u_spawn_monster": "GROUP_YOUR_FEARS", + "group": true, + "real_count": 0, + "hallucination_count": { "math": [ "rand(2) + 1" ] }, + "outdoor_only": false, + "min_radius": 10, + "max_radius": 40, + "lifespan": [ "1 hours", "4 hours" ] } } ] diff --git a/data/json/effects_on_condition/mutation_eocs/mutation_effect_eocs.json b/data/json/effects_on_condition/mutation_eocs/mutation_effect_eocs.json index 2a88ccc358857..4d46ce493410b 100644 --- a/data/json/effects_on_condition/mutation_eocs/mutation_effect_eocs.json +++ b/data/json/effects_on_condition/mutation_eocs/mutation_effect_eocs.json @@ -691,8 +691,7 @@ ] }, "effect": [ - { "u_lose_effect": "social_dissatisfied" }, - { "u_lose_effect": "social_satisfied" }, + { "u_lose_effect": [ "social_dissatisfied", "social_satisfied" ] }, { "u_add_effect": "social_satisfied", "duration": "2 hours" } ] }, @@ -709,8 +708,7 @@ ] }, "effect": [ - { "u_lose_effect": "social_dissatisfied" }, - { "u_lose_effect": "social_satisfied" }, + { "u_lose_effect": [ "social_dissatisfied", "social_satisfied" ] }, { "u_add_effect": "social_satisfied", "duration": "6 hours" } ] }, @@ -752,8 +750,7 @@ ] }, "effect": [ - { "u_lose_effect": "asocial_dissatisfied" }, - { "u_lose_effect": "asocial_satisfied" }, + { "u_lose_effect": [ "asocial_dissatisfied", "asocial_satisfied" ] }, { "u_add_effect": "asocial_satisfied", "duration": "2 hours" } ] }, @@ -806,7 +803,7 @@ { "or": [ { "u_has_effect": "social_dissatisfied" }, { "u_has_effect": "social_dissatisfied" } ] } ] }, - "effect": [ { "u_lose_effect": "asocial_dissatisfied" }, { "u_lose_effect": "social_dissatisfied" } ] + "effect": [ { "u_lose_effect": [ "asocial_dissatisfied", "social_dissatisfied" ] } ] }, { "type": "effect_on_condition", diff --git a/data/json/effects_on_condition/nether_eocs/portal_dependent_effect_on_condition.json b/data/json/effects_on_condition/nether_eocs/portal_dependent_effect_on_condition.json index b8c99aa461541..00ab0e3f88771 100644 --- a/data/json/effects_on_condition/nether_eocs/portal_dependent_effect_on_condition.json +++ b/data/json/effects_on_condition/nether_eocs/portal_dependent_effect_on_condition.json @@ -32,24 +32,21 @@ } }, "effect": { - "run_eocs": { - "id": "EOC_PDEPENDENT_STRONG_WEAK_EFFECTS_ACCEPTANCE", - "condition": { "math": [ "ps_str > 4" ] }, - "effect": { - "weighted_list_eocs": [ - [ "EOC_PORTAL_DEPENDENT_MESSAGES_GOOD", 10 ], - [ "EOC_PORTAL_DEPENDENT_MORALE_GOOD", 6 ], - [ "EOC_PORTAL_DEPENDENT_FOCUS_GOOD", 3 ], - [ "EOC_PORTAL_DEPENDENT_ACCEPTANCE", 1 ] - ] - }, - "false_effect": { - "weighted_list_eocs": [ - [ "EOC_PORTAL_DEPENDENT_MESSAGES_GOOD", 10 ], - [ "EOC_PORTAL_DEPENDENT_MORALE_GOOD", 5 ], - [ "EOC_PORTAL_DEPENDENT_FOCUS_GOOD", 2 ] - ] - } + "if": { "math": [ "ps_str > 4" ] }, + "then": { + "weighted_list_eocs": [ + [ "EOC_PORTAL_DEPENDENT_MESSAGES_GOOD", 10 ], + [ "EOC_PORTAL_DEPENDENT_MORALE_GOOD", 6 ], + [ "EOC_PORTAL_DEPENDENT_FOCUS_GOOD", 3 ], + [ "EOC_PORTAL_DEPENDENT_ACCEPTANCE", 1 ] + ] + }, + "else": { + "weighted_list_eocs": [ + [ "EOC_PORTAL_DEPENDENT_MESSAGES_GOOD", 10 ], + [ "EOC_PORTAL_DEPENDENT_MORALE_GOOD", 5 ], + [ "EOC_PORTAL_DEPENDENT_FOCUS_GOOD", 2 ] + ] } } }, @@ -142,20 +139,17 @@ ] }, "effect": { - "run_eocs": { - "id": "EOC_PORTAL_DEPENDENT_ACCEPTANCE_OUTSIDE", - "condition": "u_is_outside", - "effect": [ - { - "u_message": "You suddenly feel a profound sense of belonging take root inside you, spreading throughout your body. It fades quickly, but something warm remains…", - "type": "good" - }, - { "u_add_trait": "REALITY_GRASP" } - ], - "false_effect": { - "u_message": "You suddenly feel a profound sense of belonging take root inside you, but then abruptly grow cold. You reach out for it, but it's gone now, taken away by the indoors. You long for the sky…", - "type": "warning" - } + "if": "u_is_outside", + "then": [ + { + "u_message": "You suddenly feel a profound sense of belonging take root inside you, spreading throughout your body. It fades quickly, but something warm remains…", + "type": "good" + }, + { "u_add_trait": "REALITY_GRASP" } + ], + "else": { + "u_message": "You suddenly feel a profound sense of belonging take root inside you, but then abruptly grow cold. You reach out for it, but it's gone now, taken away by the indoors. You long for the sky…", + "type": "warning" } } }, @@ -213,34 +207,31 @@ ] }, "effect": { - "run_eocs": { - "id": "EOC_PDEPENDENT_STRONG_WEAK_EFFECTS_REJECTION", - "condition": { "not": { "u_has_trait": "REALITY_GRASP" } }, - "effect": { - "weighted_list_eocs": [ - [ "EOC_PORTAL_DEPENDENT_MESSAGES_BAD", 18 ], - [ "EOC_PORTAL_DEPENDENT_MORALE_BAD", 6 ], - [ "EOC_PORTAL_DEPENDENT_FOCUS_BAD", 5 ], - [ "EOC_PORTAL_DEPENDENT_SHAKES", 4 ], - [ "EOC_PORTAL_DEPENDENT_NAUSEA", 4 ], - [ "EOC_PORTAL_DEPENDENT_STUN", 3 ], - [ "EOC_PORTAL_DEPENDENT_DOWNED", 3 ], - [ "EOC_PORTAL_DEPENDENT_STATS_BAD", 3 ], - [ "EOC_PORTAL_TELEPORT_STUCK_START", 3 ], - [ "EOC_PORTAL_DEPENDENT_PAIN", 2 ], - [ "EOC_PORTAL_DEPENDENT_PAIN_CONSTANT", 1 ], - [ "EOC_PORTAL_DEPENDENT_DAMAGE_CONSTANT", 1 ] - ] - }, - "false_effect": { - "weighted_list_eocs": [ - [ "EOC_PORTAL_DEPENDENT_MESSAGES_BAD", 10 ], - [ "EOC_PORTAL_DEPENDENT_MORALE_BAD", 3 ], - [ "EOC_PORTAL_DEPENDENT_FOCUS_BAD", 2 ], - [ "EOC_PORTAL_DEPENDENT_SHAKES", 1 ], - [ "EOC_PORTAL_DEPENDENT_NAUSEA", 1 ] - ] - } + "if": { "not": { "u_has_trait": "REALITY_GRASP" } }, + "then": { + "weighted_list_eocs": [ + [ "EOC_PORTAL_DEPENDENT_MESSAGES_BAD", 18 ], + [ "EOC_PORTAL_DEPENDENT_MORALE_BAD", 6 ], + [ "EOC_PORTAL_DEPENDENT_FOCUS_BAD", 5 ], + [ "EOC_PORTAL_DEPENDENT_SHAKES", 4 ], + [ "EOC_PORTAL_DEPENDENT_NAUSEA", 4 ], + [ "EOC_PORTAL_DEPENDENT_STUN", 3 ], + [ "EOC_PORTAL_DEPENDENT_DOWNED", 3 ], + [ "EOC_PORTAL_DEPENDENT_STATS_BAD", 3 ], + [ "EOC_PORTAL_TELEPORT_STUCK_START", 3 ], + [ "EOC_PORTAL_DEPENDENT_PAIN", 2 ], + [ "EOC_PORTAL_DEPENDENT_PAIN_CONSTANT", 1 ], + [ "EOC_PORTAL_DEPENDENT_DAMAGE_CONSTANT", 1 ] + ] + }, + "else": { + "weighted_list_eocs": [ + [ "EOC_PORTAL_DEPENDENT_MESSAGES_BAD", 10 ], + [ "EOC_PORTAL_DEPENDENT_MORALE_BAD", 3 ], + [ "EOC_PORTAL_DEPENDENT_FOCUS_BAD", 2 ], + [ "EOC_PORTAL_DEPENDENT_SHAKES", 1 ], + [ "EOC_PORTAL_DEPENDENT_NAUSEA", 1 ] + ] } } }, @@ -275,21 +266,14 @@ "id": "EOC_PORTAL_DEPENDENT_STATS_BAD", "//": "Stats debuffs as consequence of your unstable condition.", "condition": { "not": { "u_has_effect": "sleep" } }, - "effect": [ - { - "run_eocs": { - "id": "EOC_PORTAL_DEPENDENT_STATS_EFFECTS", - "effect": { - "weighted_list_eocs": [ - [ "EOC_PORTAL_DEPENDENT_STR_BAD", 1 ], - [ "EOC_PORTAL_DEPENDENT_DEX_BAD", 1 ], - [ "EOC_PORTAL_DEPENDENT_PER_BAD", 1 ], - [ "EOC_PORTAL_DEPENDENT_INT_BAD", 1 ] - ] - } - } - } - ] + "effect": { + "weighted_list_eocs": [ + [ "EOC_PORTAL_DEPENDENT_STR_BAD", 1 ], + [ "EOC_PORTAL_DEPENDENT_DEX_BAD", 1 ], + [ "EOC_PORTAL_DEPENDENT_PER_BAD", 1 ], + [ "EOC_PORTAL_DEPENDENT_INT_BAD", 1 ] + ] + } }, { "type": "effect_on_condition", @@ -675,24 +659,21 @@ "//": "Final reward for experiencing a whole different reality, allowing you to partially anchor yourself to reality again.", "effect": [ { - "run_eocs": { - "id": "EOC_PORTAL_DEPENDENT_ACCEPTANCE_TRAIT", - "condition": { "not": { "u_has_trait": "REALITY_GRASP" } }, - "effect": [ - { - "u_message": "You suddenly feel a profound sense of belonging take root inside you, spreading throughout your body. It fades quickly, but something warm remains…", - "type": "good" - }, - { "u_add_trait": "REALITY_GRASP" } - ], - "false_effect": [ - { - "u_message": "You suddenly feel a profound sense of belonging take root inside you, temporally amplifying your grasp of reality. For some time you will be the master of your surroundings.", - "type": "good" - }, - { "u_add_effect": "pd_strengthened_reality", "duration": "14 days", "intensity": 4 } - ] - } + "if": { "not": { "u_has_trait": "REALITY_GRASP" } }, + "then": [ + { + "u_message": "You suddenly feel a profound sense of belonging take root inside you, spreading throughout your body. It fades quickly, but something warm remains…", + "type": "good" + }, + { "u_add_trait": "REALITY_GRASP" } + ], + "else": [ + { + "u_message": "You suddenly feel a profound sense of belonging take root inside you, temporally amplifying your grasp of reality. For some time you will be the master of your surroundings.", + "type": "good" + }, + { "u_add_effect": "pd_strengthened_reality", "duration": "14 days", "intensity": 4 } + ] }, { "u_add_morale": "morale_feeling_good", diff --git a/data/json/effects_on_condition/nether_eocs/portal_storm_effect_on_condition.json b/data/json/effects_on_condition/nether_eocs/portal_storm_effect_on_condition.json index b25f357224dda..5c06e3b21691a 100644 --- a/data/json/effects_on_condition/nether_eocs/portal_storm_effect_on_condition.json +++ b/data/json/effects_on_condition/nether_eocs/portal_storm_effect_on_condition.json @@ -45,75 +45,37 @@ { "case": 0, "effect": { - "run_eocs": [ - { - "id": "EOC_PORTAL_STORM_WARN_CAN_SEE_OUTDOORS_3", - "condition": "u_is_outside", - "effect": { - "run_eocs": { - "id": "EOC_PORTAL_STORM_WARN_DAY_NIGHT_3", - "condition": "is_day", - "effect": { "u_message": "PORTAL_STORM_DAY_MESSAGES_3", "snippet": true }, - "false_effect": { "u_message": "PORTAL_STORM_NIGHT_MESSAGES_3", "snippet": true } - } - } - }, - { - "id": "EOC_PORTAL_STORM_WARN_CAN_SEE_INDOORS_3", - "condition": { "not": "u_is_outside" }, - "effect": { "u_message": "PORTAL_STORM_INDOOR_MESSAGES_3", "snippet": true } - } - ] + "if": "u_is_outside", + "then": { + "if": "is_day", + "then": { "u_message": "PORTAL_STORM_DAY_MESSAGES_3", "snippet": true }, + "else": { "u_message": "PORTAL_STORM_NIGHT_MESSAGES_3", "snippet": true } + }, + "else": { "u_message": "PORTAL_STORM_INDOOR_MESSAGES_3", "snippet": true } } }, { "case": { "global_val": "portal_storm_distance", "default": 50 }, - "effect": [ - { - "run_eocs": [ - { - "id": "EOC_PORTAL_STORM_WARN_CAN_SEE_OUTDOORS_2", - "condition": "u_is_outside", - "effect": { - "run_eocs": { - "id": "EOC_PORTAL_STORM_WARN_DAY_NIGHT_2", - "condition": "is_day", - "effect": { "u_message": "PORTAL_STORM_DAY_MESSAGES_2", "snippet": true }, - "false_effect": { "u_message": "PORTAL_STORM_NIGHT_MESSAGES_2", "snippet": true } - } - } - }, - { - "id": "EOC_PORTAL_STORM_WARN_CAN_SEE_INDOORS_2", - "condition": { "not": "u_is_outside" }, - "effect": { "u_message": "PORTAL_STORM_INDOOR_MESSAGES_2", "snippet": true } - } - ] - } - ] + "effect": { + "if": "u_is_outside", + "then": { + "if": "is_day", + "then": { "u_message": "PORTAL_STORM_DAY_MESSAGES_2", "snippet": true }, + "else": { "u_message": "PORTAL_STORM_NIGHT_MESSAGES_2", "snippet": true } + }, + "else": { "u_message": "PORTAL_STORM_INDOOR_MESSAGES_2", "snippet": true } + } }, { "case": { "global_val": "portal_storm_near_distance", "default": 100 }, "effect": { - "run_eocs": [ - { - "id": "EOC_PORTAL_STORM_WARN_CAN_SEE_OUTDOORS_1", - "condition": "u_is_outside", - "effect": { - "run_eocs": { - "id": "EOC_PORTAL_STORM_WARN_DAY_NIGHT_1", - "condition": "is_day", - "effect": { "u_message": "PORTAL_STORM_DAY_MESSAGES_1", "snippet": true }, - "false_effect": { "u_message": "PORTAL_STORM_NIGHT_MESSAGES_1", "snippet": true } - } - } - }, - { - "id": "EOC_PORTAL_STORM_WARN_CAN_SEE_INDOORS_1", - "condition": { "not": "u_is_outside" }, - "effect": { "u_message": "PORTAL_STORM_INDOOR_MESSAGES_1", "snippet": true } - } - ] + "if": "u_is_outside", + "then": { + "if": "is_day", + "then": { "u_message": "PORTAL_STORM_DAY_MESSAGES_1", "snippet": true }, + "else": { "u_message": "PORTAL_STORM_NIGHT_MESSAGES_1", "snippet": true } + }, + "else": { "u_message": "PORTAL_STORM_INDOOR_MESSAGES_1", "snippet": true } } } ] @@ -410,34 +372,25 @@ { "case": 0, "effect": { - "run_eocs": { - "id": "EOC_PORTAL_STORM_MESSAGE_INDOOR_OUTDOOR_3", - "condition": "u_is_outside", - "effect": { "u_message": "PORTAL_STORM_MESSAGES_3", "snippet": true }, - "false_effect": { "weighted_list_eocs": [ [ "EOC_PORTAL_STORM_INDOOR_MESSAGES_3", 1 ], [ "EOC_PORTAL_STORM_VOICES_3", 1 ] ] } - } + "if": "u_is_outside", + "then": { "u_message": "PORTAL_STORM_MESSAGES_3", "snippet": true }, + "else": { "weighted_list_eocs": [ [ "EOC_PORTAL_STORM_INDOOR_MESSAGES_3", 1 ], [ "EOC_PORTAL_STORM_VOICES_3", 1 ] ] } } }, { "case": { "global_val": "portal_storm_distance", "default": 50 }, "effect": { - "run_eocs": { - "id": "EOC_PORTAL_STORM_MESSAGE_INDOOR_OUTDOOR_2", - "condition": "u_is_outside", - "effect": { "u_message": "PORTAL_STORM_MESSAGES_2", "snippet": true }, - "false_effect": { "weighted_list_eocs": [ [ "EOC_PORTAL_STORM_INDOOR_MESSAGES_2", 1 ], [ "EOC_PORTAL_STORM_VOICES_2", 1 ] ] } - } + "if": "u_is_outside", + "then": { "u_message": "PORTAL_STORM_MESSAGES_2", "snippet": true }, + "else": { "weighted_list_eocs": [ [ "EOC_PORTAL_STORM_INDOOR_MESSAGES_2", 1 ], [ "EOC_PORTAL_STORM_VOICES_2", 1 ] ] } } }, { "case": { "global_val": "portal_storm_near_distance", "default": 100 }, "effect": { - "run_eocs": { - "id": "EOC_PORTAL_STORM_MESSAGE_INDOOR_OUTDOOR_1", - "condition": "u_is_outside", - "effect": { "u_message": "PORTAL_STORM_MESSAGES_1", "snippet": true }, - "false_effect": { "weighted_list_eocs": [ [ "EOC_PORTAL_STORM_INDOOR_MESSAGES_1", 1 ], [ "EOC_PORTAL_STORM_VOICES_1", 1 ] ] } - } + "if": "u_is_outside", + "then": { "u_message": "PORTAL_STORM_MESSAGES_1", "snippet": true }, + "else": { "weighted_list_eocs": [ [ "EOC_PORTAL_STORM_INDOOR_MESSAGES_1", 1 ], [ "EOC_PORTAL_STORM_VOICES_1", 1 ] ] } } } ] @@ -708,26 +661,17 @@ "//": "If its night make it bright, if its day make it dark.", "effect": [ { - "run_eocs": [ - { - "id": "portal_storm_dark_light", - "condition": "is_day", - "effect": { "custom_light_level": 0, "length": [ "1 minutes", { "math": [ "ps_str * time(' 1 m')" ] } ] }, - "false_effect": { "custom_light_level": 125, "length": [ "1 minutes", { "math": [ "ps_str * time(' 1 m')" ] } ] } - }, - { - "id": "portal_storm_outside_message", - "condition": "u_is_outside", - "effect": { - "run_eocs": { - "id": "portal_storm_dark_light_message", - "condition": "is_day", - "effect": { "u_message": "The sun is snuffed out like a candle.", "type": "bad" }, - "false_effect": { "u_message": "Some of the stars grow so bright that they hurt to look at.", "type": "bad" } - } - } - } - ] + "if": "is_day", + "then": { "custom_light_level": 0, "length": [ "1 minutes", { "math": [ "ps_str * time(' 1 m')" ] } ] }, + "else": { "custom_light_level": 125, "length": [ "1 minutes", { "math": [ "ps_str * time(' 1 m')" ] } ] } + }, + { + "if": "u_is_outside", + "then": { + "if": "is_day", + "then": { "u_message": "The sun is snuffed out like a candle.", "type": "bad" }, + "else": { "u_message": "Some of the stars grow so bright that they hurt to look at.", "type": "bad" } + } } ] }, diff --git a/data/json/effects_on_condition/scenario_specific_eocs.json b/data/json/effects_on_condition/scenario_specific_eocs.json index a574f7b14de13..783adc0a5bddd 100644 --- a/data/json/effects_on_condition/scenario_specific_eocs.json +++ b/data/json/effects_on_condition/scenario_specific_eocs.json @@ -138,34 +138,28 @@ "//": "Spawn mansion monsters near the player, either for lore or as weak obstacles.", "effect": [ { - "run_eocs": { - "id": "EOC_SEX_LAIR_SPAWNS", - "condition": { "and": [ { "u_near_om_location": "mansion_boarded_t2d_start" }, { "math": [ "rand(2) == 0" ] } ] }, - "effect": [ - { - "u_spawn_monster": "mon_zombie_resort_dancer", - "real_count": { "math": [ "1 + rand(1)" ] }, - "min_radius": 3, - "max_radius": 5 - }, - { "u_message": "What was that sound?", "type": "warning", "popup": true } - ] - } + "if": { "and": [ { "u_near_om_location": "mansion_boarded_t2d_start" }, { "math": [ "rand(2) == 0" ] } ] }, + "then": [ + { + "u_spawn_monster": "mon_zombie_resort_dancer", + "real_count": { "math": [ "1 + rand(1)" ] }, + "min_radius": 3, + "max_radius": 5 + }, + { "u_message": "What was that sound?", "type": "warning", "popup": true } + ] }, { - "run_eocs": { - "id": "EOC_PANICROOM_SPAWNS", - "condition": { "and": [ { "u_near_om_location": "mansion_boarded_t2_start" }, { "math": [ "rand(1) == 0" ] } ] }, - "effect": [ - { - "u_spawn_monster": "GROUP_SCENARIO_PANICROOM", - "group": true, - "real_count": { "math": [ "1 + rand(1)" ] }, - "max_radius": 2 - }, - { "u_message": "Is there someone else in here?", "type": "warning", "popup": true } - ] - } + "if": { "and": [ { "u_near_om_location": "mansion_boarded_t2_start" }, { "math": [ "rand(1) == 0" ] } ] }, + "then": [ + { + "u_spawn_monster": "GROUP_SCENARIO_PANICROOM", + "group": true, + "real_count": { "math": [ "1 + rand(1)" ] }, + "max_radius": 2 + }, + { "u_message": "Is there someone else in here?", "type": "warning", "popup": true } + ] }, { "u_spawn_monster": "GROUP_MANSION_PURSUERS", @@ -179,37 +173,17 @@ }, { "type": "effect_on_condition", - "id": "scenario_assassin_convict", + "id": "scenario_assassin_conv", + "eoc_type": "PROFESSION_SPECIFIC", "//": "Determines which prison the assassin is in currently to correctly place the target.", - "recurrence": 1, - "condition": { "u_has_trait": "PROF_ASSASSIN_CONVICT" }, - "deactivate_condition": { "not": { "u_has_trait": "PROF_ASSASSIN_CONVICT" } }, "effect": [ + { "if": { "u_near_om_location": "prison_1_5" }, "then": { "assign_mission": "MISSION_ASSASSIN_CONVICT_PRISON" } }, { - "run_eocs": { - "id": "EOC_ASSASSIN_CONVICT_PRISON", - "condition": { "u_near_om_location": "prison_1_5" }, - "effect": [ - { "assign_mission": "MISSION_ASSASSIN_CONVICT_PRISON" }, - { "u_message": "Now… Where is your mark?", "type": "warning", "popup": true } - ], - "false_effect": { - "run_eocs": { - "id": "EOC_ASSASSIN_CONVICT_PRISON_ISLAND", - "condition": { "u_near_om_location": "prison_alcatraz_3" }, - "effect": [ - { "assign_mission": "MISSION_ASSASSIN_CONVICT_PRISON_ISLAND1" }, - { "u_message": "Now… Where is your mark?", "type": "warning", "popup": true } - ], - "false_effect": [ - { "assign_mission": "MISSION_ASSASSIN_CONVICT_PRISON_ISLAND2" }, - { "u_message": "Now… Where is your mark?", "type": "warning", "popup": true } - ] - } - } - } + "if": { "u_near_om_location": "prison_alcatraz_3" }, + "then": { "assign_mission": "MISSION_ASSASSIN_CONVICT_PRISON_ISLAND1" }, + "else": { "assign_mission": "MISSION_ASSASSIN_CONVICT_PRISON_ISLAND2" } }, - { "u_lose_trait": "PROF_ASSASSIN_CONVICT" } + { "u_message": "Now… Where is your mark?", "type": "warning", "popup": true } ] }, { diff --git a/data/json/monster_special_attacks/spells.json b/data/json/monster_special_attacks/spells.json index dea31716e16d3..4fee8ac88a5a8 100644 --- a/data/json/monster_special_attacks/spells.json +++ b/data/json/monster_special_attacks/spells.json @@ -935,42 +935,36 @@ { "case": 5, "effect": { - "run_eocs": { - "id": "portal_storm_reflection_summon_guilt", - "condition": { - "and": [ - { "math": [ "portal_dungeon_level > 0" ] }, - { "math": [ "monsters_nearby('mon_guilt', 'location': dungeon_loc) < 1" ] } - ] - }, - "effect": { - "u_spawn_monster": "mon_guilt", - "real_count": 1, - "min_radius": 2, - "max_radius": 4, - "spawn_message": "Something deep inside you is manifested physically." - } + "if": { + "and": [ + { "math": [ "portal_dungeon_level > 0" ] }, + { "math": [ "monsters_nearby('mon_guilt', 'location': dungeon_loc) < 1" ] } + ] + }, + "then": { + "u_spawn_monster": "mon_guilt", + "real_count": 1, + "min_radius": 2, + "max_radius": 4, + "spawn_message": "Something deep inside you is manifested physically." } } }, { "case": 8, "effect": { - "run_eocs": { - "id": "portal_storm_reflection_summon_sloth", - "condition": { - "and": [ - { "math": [ "portal_dungeon_level > 0" ] }, - { "math": [ "monsters_nearby('mon_sloth', 'location': dungeon_loc) < 1" ] } - ] - }, - "effect": { - "u_spawn_monster": "mon_sloth", - "real_count": 1, - "min_radius": 2, - "max_radius": 4, - "spawn_message": "Something deep inside you is manifested physically." - } + "if": { + "and": [ + { "math": [ "portal_dungeon_level > 0" ] }, + { "math": [ "monsters_nearby('mon_sloth', 'location': dungeon_loc) < 1" ] } + ] + }, + "then": { + "u_spawn_monster": "mon_sloth", + "real_count": 1, + "min_radius": 2, + "max_radius": 4, + "spawn_message": "Something deep inside you is manifested physically." } } } diff --git a/data/json/monsters/lab_security_drones.json b/data/json/monsters/lab_security_drones.json index 1b381f30d56b3..4141372cafc08 100644 --- a/data/json/monsters/lab_security_drones.json +++ b/data/json/monsters/lab_security_drones.json @@ -21,15 +21,12 @@ "id": "GREEN_MAINTENANCE_ALARM", "effect": [ { - "run_eocs": { - "id": "bot_green_maintenance_badge_check", - "condition": { "not": { "u_has_item": "id_science_maintenance_green" } }, - "effect": [ - { "u_message": "Remain in place, unauthorized person. Security has been activated." }, - { "mapgen_update": "bots_center_garage", "om_terrain": "lab_CORE_2x1_EC_ground" } - ], - "false_effect": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ] - } + "if": { "u_has_item": "id_science_maintenance_green" }, + "then": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ], + "else": [ + { "u_message": "Remain in place, unauthorized person. Security has been activated." }, + { "mapgen_update": "bots_center_garage", "om_terrain": "lab_CORE_2x1_EC_ground" } + ] } ] }, @@ -88,16 +85,13 @@ "id": "YELLOW_MAINTENANCE_ALARM", "effect": [ { - "run_eocs": { - "id": "bot_yellow_maintenance_badge_check", - "condition": { "not": { "u_has_item": "id_science_maintenance_yellow" } }, - "effect": [ - { "u_message": "Remain in place, unauthorized person. Security has been activated." }, - { "mapgen_update": "concrete_wall_o_lab_res_8_NW", "om_terrain": "lab_res_8_NWD" }, - { "mapgen_update": "concrete_wall_o_lab_res_8_NE", "om_terrain": "lab_res_8_NED" } - ], - "false_effect": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ] - } + "if": { "u_has_item": "id_science_maintenance_yellow" }, + "then": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ], + "else": [ + { "u_message": "Remain in place, unauthorized person. Security has been activated." }, + { "mapgen_update": "concrete_wall_o_lab_res_8_NW", "om_terrain": "lab_res_8_NWD" }, + { "mapgen_update": "concrete_wall_o_lab_res_8_NE", "om_terrain": "lab_res_8_NED" } + ] } ] }, @@ -148,16 +142,13 @@ "id": "BLUE_MAINTENANCE_ALARM", "effect": [ { - "run_eocs": { - "id": "bot_blue_maintenance_badge_check", - "condition": { "not": { "u_has_item": "id_science_maintenance_blue" } }, - "effect": [ - { "u_message": "Remain in place, unauthorized person. Security has been activated." }, - { "mapgen_update": "concrete_wall_o_lab_res_8_NW", "om_terrain": "lab_2x2_cargo_NW" }, - { "mapgen_update": "concrete_wall_o_lab_res_8_NE", "om_terrain": "lab_2x2_cargo_NE" } - ], - "false_effect": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ] - } + "if": { "u_has_item": "id_science_maintenance_blue" }, + "then": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ], + "else": [ + { "u_message": "Remain in place, unauthorized person. Security has been activated." }, + { "mapgen_update": "concrete_wall_o_lab_res_8_NW", "om_terrain": "lab_2x2_cargo_NW" }, + { "mapgen_update": "concrete_wall_o_lab_res_8_NE", "om_terrain": "lab_2x2_cargo_NE" } + ] } ] }, @@ -208,16 +199,13 @@ "id": "BLUE_MAINTENANCE_ALARM2", "effect": [ { - "run_eocs": { - "id": "bot_blue_maintenance_badge_check2", - "condition": { "not": { "u_has_item": "id_science_maintenance_blue" } }, - "effect": [ - { "u_message": "Remain in place, unauthorized person. Security has been activated." }, - { "mapgen_update": "lab_security_corridor_e", "om_terrain": "underground_lab_central_-6W" }, - { "mapgen_update": "lab_security_corridor_f", "om_terrain": "underground_lab_central_-6E" } - ], - "false_effect": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ] - } + "if": { "u_has_item": "id_science_maintenance_blue" }, + "then": [ { "u_message": "Hello, valued employee." }, { "u_message": "lab_safety_maintenance_snippets", "snippet": true } ], + "else": [ + { "u_message": "Remain in place, unauthorized person. Security has been activated." }, + { "mapgen_update": "lab_security_corridor_e", "om_terrain": "underground_lab_central_-6W" }, + { "mapgen_update": "lab_security_corridor_f", "om_terrain": "underground_lab_central_-6E" } + ] } ] }, @@ -294,17 +282,14 @@ "id": "GREEN_RESEARCHER_ALARM", "effect": [ { - "run_eocs": { - "id": "bot_green_researcher_badge_check", - "condition": { "not": { "u_has_item": "id_science_mutagen_green" } }, - "effect": [ - { "u_message": "Remain in place, unauthorized person. Security has been activated." }, - { "mapgen_update": "bot_release_rearcher_green", "om_terrain": "lab_res_8_NW" }, - { "mapgen_update": "bot_release_rearcher_green_2", "om_terrain": "lab_res_8_NE" }, - { "mapgen_update": "bot_release_rearcher_green", "om_terrain": "lab_res_8_NWD" } - ], - "false_effect": [ { "u_message": "Hello, valued employee." } ] - } + "if": { "u_has_item": "id_science_mutagen_green" }, + "then": [ { "u_message": "Hello, valued employee." } ], + "else": [ + { "u_message": "Remain in place, unauthorized person. Security has been activated." }, + { "mapgen_update": "bot_release_rearcher_green", "om_terrain": "lab_res_8_NW" }, + { "mapgen_update": "bot_release_rearcher_green_2", "om_terrain": "lab_res_8_NE" }, + { "mapgen_update": "bot_release_rearcher_green", "om_terrain": "lab_res_8_NWD" } + ] } ] }, @@ -369,17 +354,14 @@ "id": "BLACK_SECURITY_ALARM", "effect": [ { - "run_eocs": { - "id": "bot_black_security_badge_check", - "condition": { "not": { "u_has_item": "id_science_security_black" } }, - "effect": [ - { "u_message": "Remain in place, unauthorized person. Security has been activated." }, - { "mapgen_update": "toxic_gas_corridor", "om_terrain": "underground_lab_central_-6W" }, - { "mapgen_update": "lab_security_corridor_c", "om_terrain": "underground_lab_central_-6W" }, - { "mapgen_update": "lab_security_corridor_d", "om_terrain": "underground_lab_central_-6E" } - ], - "false_effect": [ { "u_message": "Hello, valued employee." } ] - } + "if": { "u_has_item": "id_science_security_black" }, + "then": [ { "u_message": "Hello, valued employee." } ], + "else": [ + { "u_message": "Remain in place, unauthorized person. Security has been activated." }, + { "mapgen_update": "toxic_gas_corridor", "om_terrain": "underground_lab_central_-6W" }, + { "mapgen_update": "lab_security_corridor_c", "om_terrain": "underground_lab_central_-6W" }, + { "mapgen_update": "lab_security_corridor_d", "om_terrain": "underground_lab_central_-6E" } + ] } ] }, diff --git a/data/json/mutations/mutations.json b/data/json/mutations/mutations.json index acbb55eb8e52d..0d7faf4735632 100644 --- a/data/json/mutations/mutations.json +++ b/data/json/mutations/mutations.json @@ -1598,15 +1598,6 @@ "category": [ "BEAST", "CHIMERA", "MOUSE", "RABBIT", "FELINE", "RAT" ], "enchantments": [ { "values": [ { "value": "SLEEPINESS_REGEN", "multiply": 0.333 }, { "value": "SLEEPINESS", "multiply": 0.333 } ] } ] }, - { - "type": "mutation", - "id": "PROF_ASSASSIN_CONVICT", - "name": { "str": "Assassin Convict" }, - "points": 0, - "description": "You have a target to kill. Search it, find it, and eliminate whatever it is now.", - "valid": false, - "purifiable": false - }, { "type": "mutation", "id": "ASTHMA", diff --git a/data/json/npcs/tacoma_ranch/NPC_ranch_woodcutter1.json b/data/json/npcs/tacoma_ranch/NPC_ranch_woodcutter1.json index b1d7b46a381d8..1103a97359f68 100644 --- a/data/json/npcs/tacoma_ranch/NPC_ranch_woodcutter1.json +++ b/data/json/npcs/tacoma_ranch/NPC_ranch_woodcutter1.json @@ -54,16 +54,9 @@ "topic": "TALK_DONE", "effect": [ { "u_consume_item": "FMCNote", "count": 800 }, - { - "run_eocs": { - "id": "EOC_10_logs", - "effect": [ - { "mapgen_update": "tacoma_commune_woodcutter_10_logs", "om_terrain": "ranch_camp_67" }, - { "u_message": " drops the logs off in the garage…", "type": "good", "popup": true }, - { "npc_add_effect": "currently_busy", "duration": "24 h" } - ] - } - } + { "mapgen_update": "tacoma_commune_woodcutter_10_logs", "om_terrain": "ranch_camp_67" }, + { "u_message": " drops the logs off in the garage…", "type": "good", "popup": true }, + { "npc_add_effect": "currently_busy", "duration": "24 h" } ], "condition": { "u_has_items": { "item": "FMCNote", "count": 800 } } }, @@ -72,16 +65,9 @@ "topic": "TALK_DONE", "effect": [ { "u_consume_item": "FMCNote", "count": 4800 }, - { - "run_eocs": { - "id": "EOC_100_logs", - "effect": [ - { "mapgen_update": "tacoma_commune_woodcutter_100_logs", "om_terrain": "ranch_camp_67" }, - { "u_message": " drops the logs off in the garage…", "type": "good", "popup": true }, - { "npc_add_effect": "currently_busy", "duration": "168 h" } - ] - } - } + { "mapgen_update": "tacoma_commune_woodcutter_100_logs", "om_terrain": "ranch_camp_67" }, + { "u_message": " drops the logs off in the garage…", "type": "good", "popup": true }, + { "npc_add_effect": "currently_busy", "duration": "168 h" } ], "condition": { "u_has_items": { "item": "FMCNote", "count": 4800 } } }, diff --git a/data/json/obsoletion_and_migration_0.I/obsolete_eoc.json b/data/json/obsoletion_and_migration_0.I/obsolete_eoc.json index ad74afa19567a..bb6fdc437bb3c 100644 --- a/data/json/obsoletion_and_migration_0.I/obsolete_eoc.json +++ b/data/json/obsoletion_and_migration_0.I/obsolete_eoc.json @@ -38,5 +38,9 @@ { "id": "EOC_vitrified_farm_entry", "type": "effect_on_condition" + }, + { + "id": "scenario_assassin_convict", + "type": "effect_on_condition" } ] diff --git a/data/json/obsoletion_and_migration_0.I/obsolete_traits.json b/data/json/obsoletion_and_migration_0.I/obsolete_traits.json index 50c62b5585c31..0cda2d0d0795f 100644 --- a/data/json/obsoletion_and_migration_0.I/obsolete_traits.json +++ b/data/json/obsoletion_and_migration_0.I/obsolete_traits.json @@ -3,5 +3,10 @@ "type": "TRAIT_MIGRATION", "id": "EAGLEEYED_NIGHT", "trait": "EAGLEEYED" + }, + { + "type": "TRAIT_MIGRATION", + "id": "PROF_ASSASSIN_CONVICT", + "remove": true } ] diff --git a/data/json/professions.json b/data/json/professions.json index 39a29e605b0c2..13c0ced45b038 100644 --- a/data/json/professions.json +++ b/data/json/professions.json @@ -4636,7 +4636,7 @@ "prof_shivs_familiar", "prof_gross_anatomy" ], - "traits": [ "PROF_ASSASSIN_CONVICT" ], + "effect_on_conditions": [ "scenario_assassin_conv" ], "items": { "both": { "entries": [ diff --git a/data/mods/BombasticPerks/perkdata/grit_your_teeth.json b/data/mods/BombasticPerks/perkdata/grit_your_teeth.json index 11bcd9f54164d..0cb07dde1266f 100644 --- a/data/mods/BombasticPerks/perkdata/grit_your_teeth.json +++ b/data/mods/BombasticPerks/perkdata/grit_your_teeth.json @@ -32,20 +32,17 @@ ], "false_effect": [ { - "run_eocs": { - "id": "EOC_PERK_GRIT_YOUR_TEETH_3", - "condition": { "math": [ "u_grit_your_teeth_pain_value >= 30" ] }, - "effect": [ - { "math": [ "u_grit_your_teeth_pain_value_removed = 30" ] }, - { "math": [ "u_pain()", "-=", "u_grit_your_teeth_pain_value_removed" ] }, - { "run_eocs": "EOC_PERK_GRIT_YOUR_TEETH_DEACTIVATE", "time_in_future": 180 } - ], - "false_effect": [ - { "math": [ "u_grit_your_teeth_pain_value_removed = u_pain()" ] }, - { "math": [ "u_pain() = 0" ] }, - { "run_eocs": "EOC_PERK_GRIT_YOUR_TEETH_DEACTIVATE", "time_in_future": 180 } - ] - } + "if": { "math": [ "u_grit_your_teeth_pain_value >= 30" ] }, + "then": [ + { "math": [ "u_grit_your_teeth_pain_value_removed = 30" ] }, + { "math": [ "u_pain()", "-=", "u_grit_your_teeth_pain_value_removed" ] }, + { "run_eocs": "EOC_PERK_GRIT_YOUR_TEETH_DEACTIVATE", "time_in_future": 180 } + ], + "else": [ + { "math": [ "u_grit_your_teeth_pain_value_removed = u_pain()" ] }, + { "math": [ "u_pain() = 0" ] }, + { "run_eocs": "EOC_PERK_GRIT_YOUR_TEETH_DEACTIVATE", "time_in_future": 180 } + ] } ] }, diff --git a/data/mods/BombasticPerks/perkdata/moonstruck.json b/data/mods/BombasticPerks/perkdata/moonstruck.json index 37e184e6ac3d4..1ede0dafbe286 100644 --- a/data/mods/BombasticPerks/perkdata/moonstruck.json +++ b/data/mods/BombasticPerks/perkdata/moonstruck.json @@ -62,48 +62,39 @@ "recurrence": [ "1 hours", "1 hours" ], "condition": { "u_has_trait": "perk_moonstruck" }, "deactivate_condition": { "not": { "u_has_trait": "perk_moonstruck" } }, - "effect": { - "run_eocs": [ - { - "id": "EOC_PERK_MOONSTRUCK_2", - "condition": { "math": [ "moon_phase() == 4" ] }, - "effect": [ - { "u_lose_effect": "effect_perk_moonstruck_full" }, - { "u_lose_effect": "effect_perk_moonstruck_waxing" }, - { "u_lose_effect": "effect_perk_moonstruck_new" }, - { "u_add_effect": "effect_perk_moonstruck_full", "duration": "2 hours" } - ], - "false_effect": { - "run_eocs": { - "id": "EOC_PERK_MOONSTRUCK_3", - "condition": { "and": [ { "math": [ "moon_phase() <= 3" ] }, { "math": [ "moon_phase() >= 1" ] } ] }, - "effect": [ - { "u_lose_effect": "effect_perk_moonstruck_full" }, - { "u_lose_effect": "effect_perk_moonstruck_waxing" }, - { "u_lose_effect": "effect_perk_moonstruck_new" }, - { "u_add_effect": "effect_perk_moonstruck_waxing", "duration": "2 hours" } - ], - "false_effect": { - "run_eocs": { - "id": "EOC_PERK_MOONSTRUCK_4", - "condition": { "math": [ "moon_phase() == 0" ] }, - "effect": [ - { "u_lose_effect": "effect_perk_moonstruck_full" }, - { "u_lose_effect": "effect_perk_moonstruck_waxing" }, - { "u_lose_effect": "effect_perk_moonstruck_new" }, - { "u_add_effect": "effect_perk_moonstruck_new", "duration": "2 hours" } - ], - "false_effect": [ - { "u_lose_effect": "effect_perk_moonstruck_full" }, - { "u_lose_effect": "effect_perk_moonstruck_waxing" }, - { "u_lose_effect": "effect_perk_moonstruck_new" } - ] - } - } - } + "effect": [ + { + "switch": { "math": [ "moon_phase()" ] }, + "cases": [ + { + "case": 0, + "effect": [ + { "u_lose_effect": [ "effect_perk_moonstruck_full", "effect_perk_moonstruck_waxing", "effect_perk_moonstruck_new" ] }, + { "u_add_effect": "effect_perk_moonstruck_new", "duration": "2 hours" } + ] + }, + { + "case": 3, + "effect": [ + { "u_lose_effect": [ "effect_perk_moonstruck_full", "effect_perk_moonstruck_waxing", "effect_perk_moonstruck_new" ] }, + { "u_add_effect": "effect_perk_moonstruck_waxing", "duration": "2 hours" } + ] + }, + { + "case": 4, + "effect": [ + { "u_lose_effect": [ "effect_perk_moonstruck_full", "effect_perk_moonstruck_waxing", "effect_perk_moonstruck_new" ] }, + { "u_add_effect": "effect_perk_moonstruck_full", "duration": "2 hours" } + ] + }, + { + "case": 7, + "effect": [ + { "u_lose_effect": [ "effect_perk_moonstruck_full", "effect_perk_moonstruck_waxing", "effect_perk_moonstruck_new" ] } + ] } - } - ] - } + ] + } + ] } ] diff --git a/data/mods/Defense_Mode/effects_on_condition/backend_eocs.json b/data/mods/Defense_Mode/effects_on_condition/backend_eocs.json index adec2409dd0aa..c745fc1f81627 100644 --- a/data/mods/Defense_Mode/effects_on_condition/backend_eocs.json +++ b/data/mods/Defense_Mode/effects_on_condition/backend_eocs.json @@ -78,12 +78,7 @@ "eoc_type": "PREVENT_DEATH", "condition": { "math": [ "revivication_counter >= 1" ] }, "effect": [ - { "u_lose_effect": "hypovolemia" }, - { "u_lose_effect": "redcells_anemia" }, - { "u_lose_effect": "grabbed" }, - { "u_lose_effect": "staggered" }, - { "u_lose_effect": "bite" }, - { "u_lose_effect": "bleed" }, + { "u_lose_effect": [ "hypovolemia", "redcells_anemia", "grabbed", "staggered", "bite", "bleed" ] }, { "math": [ "u_calories() = u_calories()" ] }, { "math": [ "u_val('pkill') = u_val('pkill')" ] }, { "math": [ "u_val('stim') = u_val('stim')" ] }, diff --git a/data/mods/Magiclysm/Spells/classless.json b/data/mods/Magiclysm/Spells/classless.json index 501ac25a5262b..08f6151ac44bf 100644 --- a/data/mods/Magiclysm/Spells/classless.json +++ b/data/mods/Magiclysm/Spells/classless.json @@ -513,18 +513,8 @@ "type": "effect_on_condition", "id": "EOC_CLASSLESS_CLEAN_CLOTHING_AND_SELF", "effect": [ - { "u_lose_effect": "bile_irritant" }, - { "u_lose_effect": "bile_stink" }, + { "u_lose_effect": [ "bile_irritant", "bile_stink", "boomered", "skunk_spray", "wet" ], "target_part": "ALL" }, { "u_lose_morale": "morale_bile" }, - { "u_lose_effect": "boomered", "target_part": "eyes" }, - { "u_lose_effect": "skunk_spray" }, - { "u_lose_effect": "wet" }, - { "u_lose_effect": "wet", "target_part": "head" }, - { "u_lose_effect": "wet", "target_part": "arm_l" }, - { "u_lose_effect": "wet", "target_part": "arm_r" }, - { "u_lose_effect": "wet", "target_part": "torso" }, - { "u_lose_effect": "wet", "target_part": "leg_l" }, - { "u_lose_effect": "wet", "target_part": "leg_r" }, { "u_run_inv_eocs": "all", "search_data": [ { "worn_only": true }, { "flags": [ "FILTHY" ] } ], diff --git a/data/mods/Magiclysm/effect_on_conditions/effect_removers.json b/data/mods/Magiclysm/effect_on_conditions/effect_removers.json index fa8dbf1bf5133..5df7f2bfa8e29 100644 --- a/data/mods/Magiclysm/effect_on_conditions/effect_removers.json +++ b/data/mods/Magiclysm/effect_on_conditions/effect_removers.json @@ -12,8 +12,7 @@ ] }, "effect": [ - { "u_lose_effect": "effect_shape_of_dust" }, - { "u_lose_effect": "effect_technomancer_invisibility" }, + { "u_lose_effect": [ "effect_shape_of_dust", "effect_technomancer_invisibility" ] }, { "npc_lose_effect": "telepathic_ignorance" } ] }, @@ -30,8 +29,7 @@ ] }, "effect": [ - { "u_lose_effect": "effect_shape_of_dust" }, - { "u_lose_effect": "effect_technomancer_invisibility" }, + { "u_lose_effect": [ "effect_shape_of_dust", "effect_technomancer_invisibility" ] }, { "npc_lose_effect": "telepathic_ignorance" } ] } diff --git a/data/mods/MindOverMatter/effectoncondition/eoc_misc.json b/data/mods/MindOverMatter/effectoncondition/eoc_misc.json index c3f85fe1a5a40..94deb75885c3e 100644 --- a/data/mods/MindOverMatter/effectoncondition/eoc_misc.json +++ b/data/mods/MindOverMatter/effectoncondition/eoc_misc.json @@ -222,8 +222,7 @@ "id": "EOC_MINDOVERMATTER_PRE_CONJUNCTIVITIS_VIRAL_TO_CONJUNCTIVITIS_VIRAL", "condition": { "u_has_effect": "pre_conjunctivitis_viral" }, "effect": [ - { "u_lose_effect": "pre_conjunctivitis_viral" }, - { "u_lose_effect": "pre_conjunctivitis_bacterial" }, + { "u_lose_effect": [ "pre_conjunctivitis_viral", "pre_conjunctivitis_bacterial" ] }, { "u_add_effect": "conjunctivitis_viral", "duration": { "math": [ "rand(259200) + 432000" ] }, @@ -236,8 +235,7 @@ "id": "EOC_MINDOVERMATTER_PRE_CONJUNCTIVITIS_BACTERIAL_TO_CONJUNCTIVITIS_BACTERIAL", "condition": { "u_has_effect": "pre_conjunctivitis_bacterial" }, "effect": [ - { "u_lose_effect": "pre_conjunctivitis_viral" }, - { "u_lose_effect": "pre_conjunctivitis_bacterial" }, + { "u_lose_effect": [ "pre_conjunctivitis_viral", "pre_conjunctivitis_bacterial" ] }, { "u_add_effect": "conjunctivitis_bacterial", "duration": { "math": [ "rand(259200) + 432000" ] }, diff --git a/data/mods/MindOverMatter/effectoncondition/eoc_on_power_use_events.json b/data/mods/MindOverMatter/effectoncondition/eoc_on_power_use_events.json index 2f192c5aaa730..da9d9ff72603b 100644 --- a/data/mods/MindOverMatter/effectoncondition/eoc_on_power_use_events.json +++ b/data/mods/MindOverMatter/effectoncondition/eoc_on_power_use_events.json @@ -20,8 +20,7 @@ "EOC_TELEPATH_REMOVE_TELEPATHIC_CONCENTRATION" ] }, - { "u_lose_effect": "telepathic_ignorance_self" }, - { "u_lose_effect": "effect_clair_perfect_shot" } + { "u_lose_effect": [ "telepathic_ignorance_self", "effect_clair_perfect_shot" ] } ] }, { @@ -66,7 +65,7 @@ "eoc_type": "EVENT", "required_event": "avatar_moves", "condition": { "or": [ { "u_has_effect": "effect_biokin_hurricane_blows" }, { "u_has_effect": "effect_biokin_hurricane_blows_2" } ] }, - "effect": [ { "u_lose_effect": "effect_biokin_hurricane_blows" }, { "u_lose_effect": "effect_biokin_hurricane_blows_2" } ] + "effect": [ { "u_lose_effect": [ "effect_biokin_hurricane_blows", "effect_biokin_hurricane_blows_2" ] } ] }, { "type": "effect_on_condition", diff --git a/data/mods/MindOverMatter/effectoncondition/eoc_potions.json b/data/mods/MindOverMatter/effectoncondition/eoc_potions.json index fc5d67e5519f1..7c73995340702 100644 --- a/data/mods/MindOverMatter/effectoncondition/eoc_potions.json +++ b/data/mods/MindOverMatter/effectoncondition/eoc_potions.json @@ -19,8 +19,7 @@ "type": "effect_on_condition", "id": "EOC_BIOKIN_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_biokin_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_biokin_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_biokin_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] }, @@ -44,8 +43,7 @@ "type": "effect_on_condition", "id": "EOC_CLAIR_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_clair_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_clair_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_clair_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] }, @@ -76,8 +74,7 @@ "type": "effect_on_condition", "id": "EOC_ELECTROKIN_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_electrokin_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_electrokin_potion", "effect_matrix_potion_nether_boost" ] }, { "if": { "math": [ "u_preexisting_jittery_trait != 1" ] }, "then": { "u_add_trait": "JITTERY" } }, { "u_add_effect": "effect_electrokin_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] @@ -111,8 +108,7 @@ "type": "effect_on_condition", "id": "EOC_PHOTOKIN_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_photokin_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_photokin_potion", "effect_matrix_potion_nether_boost" ] }, { "u_lose_trait": "PHOTOLIXIR_LIGHT" }, { "u_lose_trait": "PHOTOLIXIR_LIGHT_active" }, { "u_add_effect": "effect_photokin_potion_comedown", "duration": [ "24 hours", "55 hours" ] } @@ -138,8 +134,7 @@ "type": "effect_on_condition", "id": "EOC_PYROKIN_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_pyrokin_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_pyrokin_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_pyrokin_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] }, @@ -164,8 +159,7 @@ "type": "effect_on_condition", "id": "EOC_TELEKIN_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_telekin_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_telekin_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_telekin_potion_comedown", "duration": [ "24 hours", "55 hours" ] }, { "u_lose_trait": "TELELIXIRDOWN" }, { "u_lose_trait": "TELELIXIRDOWN_active" } @@ -191,8 +185,7 @@ "type": "effect_on_condition", "id": "EOC_TELEPATH_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_telepath_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_telepath_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_telepath_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] }, @@ -216,8 +209,7 @@ "type": "effect_on_condition", "id": "EOC_TELEPORT_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_teleport_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_teleport_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_teleport_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] }, @@ -253,8 +245,7 @@ "type": "effect_on_condition", "id": "EOC_VITAKIN_POTION_COMEDOWN", "effect": [ - { "u_lose_effect": "effect_vitakin_potion" }, - { "u_lose_effect": "effect_matrix_potion_nether_boost" }, + { "u_lose_effect": [ "effect_vitakin_potion", "effect_matrix_potion_nether_boost" ] }, { "u_add_effect": "effect_vitakin_potion_comedown", "duration": [ "24 hours", "55 hours" ] } ] }, diff --git a/data/mods/MindOverMatter/effectoncondition/eoc_power_effects.json b/data/mods/MindOverMatter/effectoncondition/eoc_power_effects.json index e31122d10eaa4..8a216bb8783b1 100644 --- a/data/mods/MindOverMatter/effectoncondition/eoc_power_effects.json +++ b/data/mods/MindOverMatter/effectoncondition/eoc_power_effects.json @@ -335,21 +335,25 @@ "EOC_VITAKIN_REMOVE_RETURN_FROM_DEATH" ] }, - { "u_lose_effect": "effect_biokin_sealed" }, - { "u_lose_effect": "effect_biokin_combat_dance" }, - { "u_lose_effect": "effect_biokin_perfected_motion" }, - { "u_lose_effect": "effect_clair_sense_rads_self" }, + { + "u_lose_effect": [ + "effect_biokin_sealed", + "effect_biokin_combat_dance", + "effect_biokin_perfected_motion", + "effect_clair_sense_rads_self", + "effect_clair_perfect_shot", + "effect_clair_omniscence", + "effect_photokin_arms", + "effect_telekinetic_slowfall", + "effect_telekinetic_aegis", + "effect_telepath_invisibility", + "effect_telepath_network_effect", + "effect_vitakin_purge_rads", + "effect_psi_intense_concentration" + ] + }, { "u_remove_item_with": "clair_sense_rad_item" }, - { "u_lose_effect": "effect_clair_perfect_shot" }, - { "u_lose_effect": "effect_clair_omniscence" }, - { "u_lose_effect": "effect_photokin_arms" }, - { "u_lose_effect": "effect_telekinetic_slowfall" }, - { "u_lose_effect": "effect_telekinetic_aegis" }, - { "u_lose_effect": "effect_telepath_invisibility" }, - { "u_lose_effect": "effect_telepath_network_effect" }, - { "u_lose_effect": "effect_vitakin_purge_rads" }, - { "math": [ "u_vitamin('vitamin_maintained_powers') = 0" ] }, - { "u_lose_effect": "effect_psi_intense_concentration" } + { "math": [ "u_vitamin('vitamin_maintained_powers') = 0" ] } ] }, { diff --git a/data/mods/MindOverMatter/powers/biokinesis_concentration_eocs.json b/data/mods/MindOverMatter/powers/biokinesis_concentration_eocs.json index 2170e38406078..56a1cc09c168e 100644 --- a/data/mods/MindOverMatter/powers/biokinesis_concentration_eocs.json +++ b/data/mods/MindOverMatter/powers/biokinesis_concentration_eocs.json @@ -45,13 +45,17 @@ "id": "EOC_BIOKIN_REMOVE_OVERCOME_PAIN", "condition": { "u_has_effect": "effect_biokin_overcome_pain" }, "effect": [ - { "u_lose_effect": "effect_biokin_pkill_1" }, - { "u_lose_effect": "effect_biokin_pkill_2" }, - { "u_lose_effect": "effect_biokin_pkill_3" }, - { "u_lose_effect": "effect_biokin_pkill_4" }, - { "u_lose_effect": "effect_biokin_pkill_5" }, - { "u_lose_effect": "effect_biokin_pkill_6" }, - { "u_lose_effect": "effect_biokin_overcome_pain" }, + { + "u_lose_effect": [ + "effect_biokin_pkill_1", + "effect_biokin_pkill_2", + "effect_biokin_pkill_3", + "effect_biokin_pkill_4", + "effect_biokin_pkill_5", + "effect_biokin_pkill_6", + "effect_biokin_overcome_pain" + ] + }, { "run_eocs": "EOC_POWER_MAINTENANCE_MINUS_ONE" } ] }, diff --git a/data/mods/MindOverMatter/powers/clairsentience_concentration_eocs.json b/data/mods/MindOverMatter/powers/clairsentience_concentration_eocs.json index 608a33bcde623..969022d959744 100644 --- a/data/mods/MindOverMatter/powers/clairsentience_concentration_eocs.json +++ b/data/mods/MindOverMatter/powers/clairsentience_concentration_eocs.json @@ -30,15 +30,19 @@ "id": "EOC_CLAIR_REMOVE_NIGHT_EYES", "condition": { "u_has_effect": "effect_clair_night_eyes" }, "effect": [ - { "u_lose_effect": "effect_clair_night_eyes_1" }, - { "u_lose_effect": "effect_clair_night_eyes_2" }, - { "u_lose_effect": "effect_clair_night_eyes_3" }, - { "u_lose_effect": "effect_clair_night_eyes_4" }, - { "u_lose_effect": "effect_clair_night_eyes_5" }, - { "u_lose_effect": "effect_clair_night_eyes_6" }, - { "u_lose_effect": "effect_clair_night_eyes_7" }, - { "u_lose_effect": "effect_clair_night_eyes_8" }, - { "u_lose_effect": "effect_clair_night_eyes" }, + { + "u_lose_effect": [ + "effect_clair_night_eyes_1", + "effect_clair_night_eyes_2", + "effect_clair_night_eyes_3", + "effect_clair_night_eyes_4", + "effect_clair_night_eyes_5", + "effect_clair_night_eyes_6", + "effect_clair_night_eyes_7", + "effect_clair_night_eyes_8", + "effect_clair_night_eyes" + ] + }, { "run_eocs": "EOC_POWER_MAINTENANCE_MINUS_ONE" } ] }, diff --git a/data/mods/MindOverMatter/powers/clairsentience_eoc.json b/data/mods/MindOverMatter/powers/clairsentience_eoc.json index 10cbc6084fbab..91b604eb46516 100644 --- a/data/mods/MindOverMatter/powers/clairsentience_eoc.json +++ b/data/mods/MindOverMatter/powers/clairsentience_eoc.json @@ -201,8 +201,7 @@ "id": "EOC_CLAIR_ASTRAL_PROJECTION_DEACTIVATE", "effect": [ { "u_remove_item_with": "item_clair_astral_projection_cord" }, - { "u_lose_effect": "effect_clair_astral_projection" }, - { "u_lose_effect": "incorporeal" }, + { "u_lose_effect": [ "effect_clair_astral_projection", "incorporeal" ] }, { "u_lose_trait": "CLAIR_ASTRAL_PROJECTION_APPEARANCE" }, { "math": [ "u_spell_level('clair_astral_projection_passwall') = -1" ] }, { "math": [ "u_spell_level('clair_astral_projection_return') = -1" ] }, diff --git a/data/mods/MindOverMatter/powers/learning_eocs/overall.json b/data/mods/MindOverMatter/powers/learning_eocs/overall.json index d6001c01c59d7..a7df3606ac798 100644 --- a/data/mods/MindOverMatter/powers/learning_eocs/overall.json +++ b/data/mods/MindOverMatter/powers/learning_eocs/overall.json @@ -97,7 +97,7 @@ "eoc_type": "EVENT", "required_event": "avatar_moves", "condition": { "or": [ { "u_has_effect": "effect_psi_learning_new_power" }, { "u_has_effect": "effect_psi_studying_power" } ] }, - "effect": [ { "u_lose_effect": "effect_psi_learning_new_power" }, { "u_lose_effect": "effect_psi_studying_power" } ] + "effect": [ { "u_lose_effect": [ "effect_psi_learning_new_power", "effect_psi_studying_power" ] } ] }, { "type": "effect_on_condition", @@ -105,7 +105,7 @@ "eoc_type": "EVENT", "required_event": "spellcasting_finish", "condition": { "or": [ { "u_has_effect": "effect_psi_learning_new_power" }, { "u_has_effect": "effect_psi_studying_power" } ] }, - "effect": [ { "u_lose_effect": "effect_psi_learning_new_power" }, { "u_lose_effect": "effect_psi_studying_power" } ] + "effect": [ { "u_lose_effect": [ "effect_psi_learning_new_power", "effect_psi_studying_power" ] } ] }, { "type": "effect_on_condition", @@ -125,7 +125,7 @@ } ] }, - "effect": [ { "u_lose_effect": "effect_psi_learning_new_power" }, { "u_lose_effect": "effect_psi_studying_power" } ] + "effect": [ { "u_lose_effect": [ "effect_psi_learning_new_power", "effect_psi_studying_power" ] } ] }, { "type": "effect_on_condition", @@ -146,8 +146,7 @@ ] }, "effect": [ - { "u_lose_effect": "effect_psi_learning_new_power" }, - { "u_lose_effect": "effect_psi_studying_power" }, + { "u_lose_effect": [ "effect_psi_learning_new_power", "effect_psi_studying_power" ] }, { "u_message": "You're so exhausted you can barely think straight, and certainly can't concentrate on studying your powers.", "popup": true diff --git a/data/mods/MindOverMatter/powers/telepathy_eoc.json b/data/mods/MindOverMatter/powers/telepathy_eoc.json index ebcdd43805755..15fc3e5e217fb 100644 --- a/data/mods/MindOverMatter/powers/telepathy_eoc.json +++ b/data/mods/MindOverMatter/powers/telepathy_eoc.json @@ -116,7 +116,7 @@ "eoc_type": "EVENT", "required_event": "character_takes_damage", "condition": { "and": [ { "u_has_effect": "psi_stunned" }, { "u_has_effect": "effect_telepath_mesmerize_tracker" } ] }, - "effect": [ { "u_lose_effect": "effect_telepath_mesmerize_tracker" }, { "u_lose_effect": "psi_stunned" } ] + "effect": [ { "u_lose_effect": [ "effect_telepath_mesmerize_tracker", "psi_stunned" ] } ] }, { "type": "effect_on_condition", @@ -124,7 +124,7 @@ "eoc_type": "EVENT", "required_event": "monster_takes_damage", "condition": { "and": [ { "u_has_effect": "psi_stunned" }, { "u_has_effect": "effect_telepath_mesmerize_tracker" } ] }, - "effect": [ { "u_lose_effect": "effect_telepath_mesmerize_tracker" }, { "u_lose_effect": "psi_stunned" } ] + "effect": [ { "u_lose_effect": [ "effect_telepath_mesmerize_tracker", "psi_stunned" ] } ] }, { "type": "effect_on_condition", diff --git a/data/mods/MindOverMatter/powers/vitakinesis_concentration_eoc.json b/data/mods/MindOverMatter/powers/vitakinesis_concentration_eoc.json index e10673610996a..33ff404f38a26 100644 --- a/data/mods/MindOverMatter/powers/vitakinesis_concentration_eoc.json +++ b/data/mods/MindOverMatter/powers/vitakinesis_concentration_eoc.json @@ -42,10 +42,14 @@ "id": "EOC_VITAKIN_REMOVE_SLOW_BLEEDING", "condition": { "u_has_effect": "effect_vitakin_slow_bleeding" }, "effect": [ - { "u_lose_effect": "effect_vitakin_slow_bleeding" }, - { "u_lose_effect": "effect_vitakin_slow_bleeding_01" }, - { "u_lose_effect": "effect_vitakin_slow_bleeding_02" }, - { "u_lose_effect": "effect_vitakin_slow_bleeding_03" }, + { + "u_lose_effect": [ + "effect_vitakin_slow_bleeding", + "effect_vitakin_slow_bleeding_01", + "effect_vitakin_slow_bleeding_02", + "effect_vitakin_slow_bleeding_03" + ] + }, { "run_eocs": "EOC_POWER_MAINTENANCE_MINUS_ONE" } ] }, @@ -350,19 +354,14 @@ "id": "EOC_VITAKIN_REMOVE_CONCENTRATED_HEALING", "condition": { "u_has_effect": "effect_vita_concentrated_healing" }, "effect": [ - { "u_lose_effect": "effect_vita_concentrated_healing" }, - { "u_lose_effect": "effect_vita_concentrated_healing_bonus", "target_part": "head" }, - { "u_lose_effect": "effect_vita_concentrated_healing_bonus", "target_part": "torso" }, - { "u_lose_effect": "effect_vita_concentrated_healing_bonus", "target_part": "arm_r" }, - { "u_lose_effect": "effect_vita_concentrated_healing_bonus", "target_part": "arm_l" }, - { "u_lose_effect": "effect_vita_concentrated_healing_bonus", "target_part": "leg_r" }, - { "u_lose_effect": "effect_vita_concentrated_healing_bonus", "target_part": "leg_l" }, - { "u_lose_effect": "effect_vita_concentrated_healing_penalty", "target_part": "head" }, - { "u_lose_effect": "effect_vita_concentrated_healing_penalty", "target_part": "torso" }, - { "u_lose_effect": "effect_vita_concentrated_healing_penalty", "target_part": "arm_r" }, - { "u_lose_effect": "effect_vita_concentrated_healing_penalty", "target_part": "arm_l" }, - { "u_lose_effect": "effect_vita_concentrated_healing_penalty", "target_part": "leg_r" }, - { "u_lose_effect": "effect_vita_concentrated_healing_penalty", "target_part": "leg_l" }, + { + "u_lose_effect": [ + "effect_vita_concentrated_healing", + "effect_vita_concentrated_healing_bonus", + "effect_vita_concentrated_healing_penalty" + ], + "target_part": "ALL" + }, { "run_eocs": "EOC_POWER_MAINTENANCE_MINUS_ONE" } ] }, diff --git a/data/mods/MindOverMatter/powers/vitakinesis_eoc.json b/data/mods/MindOverMatter/powers/vitakinesis_eoc.json index 5ed491bd48c82..c668b970dad1c 100644 --- a/data/mods/MindOverMatter/powers/vitakinesis_eoc.json +++ b/data/mods/MindOverMatter/powers/vitakinesis_eoc.json @@ -35,8 +35,7 @@ }, "effect": [ { "math": [ "u_vitamin('mutant_toxin')", "+=", "u_vitamin('dermatik_larva_size')" ] }, - { "u_lose_effect": "dermatik" }, - { "u_lose_effect": "dermatik_visible" }, + { "u_lose_effect": [ "dermatik", "dermatik_visible" ] }, { "math": [ "u_vitamin('dermatik_larva_size') = 0" ] }, { "u_message": "You feel a severe itching sensation.", "type": "mixed" } ], @@ -109,25 +108,10 @@ { "u_message": "You begin to sweat.", "type": "mixed" }, { "u_add_wet": 8 }, { "run_eocs": [ "EOC_VITAKIN_DEXTOXIFICATION_TOXICFLESH" ] }, - { "u_lose_effect": "poison" }, - { "u_lose_effect": "poison", "target_part": "head" }, - { "u_lose_effect": "poison", "target_part": "torso" }, - { "u_lose_effect": "poison", "target_part": "arm_r" }, - { "u_lose_effect": "poison", "target_part": "arm_l" }, - { "u_lose_effect": "poison", "target_part": "leg_r" }, - { "u_lose_effect": "poison", "target_part": "leg_l" }, - { "u_lose_effect": "badpoison" }, - { "u_lose_effect": "badpoison", "target_part": "head" }, - { "u_lose_effect": "badpoison", "target_part": "torso" }, - { "u_lose_effect": "badpoison", "target_part": "arm_r" }, - { "u_lose_effect": "badpoison", "target_part": "arm_l" }, - { "u_lose_effect": "badpoison", "target_part": "leg_r" }, - { "u_lose_effect": "badpoison", "target_part": "leg_l" }, - { "u_lose_effect": "venom_dmg" }, - { "u_lose_effect": "venom_weaken" }, - { "u_lose_effect": "venom_blind" }, - { "u_lose_effect": "venom_pain" }, - { "u_lose_effect": "paralyzepoison" } + { + "u_lose_effect": [ "poison", "badpoison", "venom_dmg", "venom_weaken", "venom_blind", "venom_pain", "paralyzepoison" ], + "target_part": "ALL" + } ] }, { @@ -739,14 +723,18 @@ }, "effect": [ { "u_message": "You feel much better.", "type": "good" }, - { "u_lose_effect": "pre_common_cold" }, - { "u_lose_effect": "common_cold" }, - { "u_lose_effect": "pre_flu" }, - { "u_lose_effect": "flu" }, - { "u_lose_effect": "pre_conjunctivitis_viral" }, - { "u_lose_effect": "conjunctivitis_viral" }, - { "u_lose_effect": "pre_conjunctivitis_bacterial" }, - { "u_lose_effect": "conjunctivitis_bacterial" }, + { + "u_lose_effect": [ + "pre_common_cold", + "common_cold", + "pre_flu", + "flu", + "pre_conjunctivitis_viral", + "conjunctivitis_viral", + "pre_conjunctivitis_bacterial", + "conjunctivitis_bacterial" + ] + }, { "math": [ "u_vitamin('vitamin_psionic_drain')", "+=", "rng( 15,30 )" ] } ], "false_effect": [ @@ -1340,19 +1328,23 @@ { "math": [ "u_vitamin('redcells') = 0" ] }, { "math": [ "u_vitamin('bad_food') = 0" ] }, { "math": [ "u_vitamin('blood') = 0" ] }, - { "u_lose_effect": "corroding" }, - { "u_lose_effect": "onfire" }, - { "u_lose_effect": "dazed" }, - { "u_lose_effect": "downed" }, - { "u_lose_effect": "stunned" }, - { "u_lose_effect": "venom_blind" }, - { "u_lose_effect": "sap" }, - { "u_lose_effect": "staggered_character" }, - { "u_lose_effect": "nausea" }, - { "u_lose_effect": "bleed" }, - { "u_lose_effect": "blind" }, - { "u_lose_effect": "deaf" }, - { "u_lose_effect": "effect_vita_return_from_death" }, + { + "u_lose_effect": [ + "corroding", + "onfire", + "dazed", + "downed", + "stunned", + "venom_blind", + "sap", + "staggered_character", + "nausea", + "bleed", + "blind", + "deaf", + "effect_vita_return_from_death" + ] + }, { "u_add_effect": "effect_vita_super_heal_return_from_death", "duration": "20 seconds" }, { "run_eocs": "EOC_VITAKIN_RETURN_FROM_DEATH_RUN_HEALING", diff --git a/data/mods/Perk_melee/EOC/eoc_clears.json b/data/mods/Perk_melee/EOC/eoc_clears.json index a9f607b659c21..4597536241daa 100644 --- a/data/mods/Perk_melee/EOC/eoc_clears.json +++ b/data/mods/Perk_melee/EOC/eoc_clears.json @@ -2,11 +2,7 @@ { "id": "EOC_CLEAR_BUFFS", "type": "effect_on_condition", - "effect": [ - { "u_lose_effect": "mabuff:buff_perk_tempo" }, - { "u_lose_effect": "mabuff:buff_perk_momentum" }, - { "u_lose_effect": "perk_dex_bonus" } - ] + "effect": [ { "u_lose_effect": [ "mabuff:buff_perk_tempo", "mabuff:buff_perk_momentum", "perk_dex_bonus" ] } ] }, { "id": "EOC_CLEAR_COMBAT_TEMPO", @@ -16,6 +12,6 @@ { "id": "EOC_CLEAR_MOMENTUM", "type": "effect_on_condition", - "effect": [ { "u_lose_effect": "mabuff:buff_perk_momentum" }, { "u_lose_effect": "perk_dex_bonus" } ] + "effect": [ { "u_lose_effect": [ "mabuff:buff_perk_momentum", "perk_dex_bonus" ] } ] } ] diff --git a/data/mods/Sky_Island/EOCs.json b/data/mods/Sky_Island/EOCs.json index c2bcce2757256..cd04243e7bc73 100644 --- a/data/mods/Sky_Island/EOCs.json +++ b/data/mods/Sky_Island/EOCs.json @@ -87,8 +87,7 @@ { "u_remove_item_with": "warphome" }, { "math": [ "raidstotal++" ] }, { "u_lose_trait": "awayfromhome" }, - { "u_lose_effect": "warpsickness" }, - { "u_lose_effect": "warpdisintegration" }, + { "u_lose_effect": [ "warpsickness", "warpdisintegration" ] }, { "run_eocs": [ "EOC_clearmissions", @@ -360,22 +359,26 @@ { "math": [ "u_val('rad') = 0" ] }, { "u_add_effect": "cureall", "duration": "1 s", "intensity": 1 }, { "u_add_effect": "panacea", "duration": "30 s", "intensity": 1 }, - { "u_lose_effect": "corroding" }, - { "u_lose_effect": "onfire" }, - { "u_lose_effect": "dazed" }, - { "u_lose_effect": "stunned" }, - { "u_lose_effect": "venom_blind" }, - { "u_lose_effect": "formication" }, - { "u_lose_effect": "blisters" }, - { "u_lose_effect": "frostbite" }, - { "u_lose_effect": "frostbite_recovery" }, - { "u_lose_effect": "wet" }, - { "u_lose_effect": "slimed" }, - { "u_lose_effect": "migo_atmosphere" }, - { "u_lose_effect": "fetid_goop" }, - { "u_lose_effect": "sap" }, - { "u_lose_effect": "nausea" }, - { "u_lose_effect": "bleed" }, + { + "u_lose_effect": [ + "corroding", + "onfire", + "dazed", + "stunned", + "venom_blind", + "formication", + "blisters", + "frostbite", + "frostbite_recovery", + "wet", + "slimed", + "migo_atmosphere", + "fetid_goop", + "sap", + "nausea", + "bleed" + ] + }, { "run_eocs": [ "EOC_FIX_MAGICLYSM_PROBLEMS", "EOC_FIX_MIND_OVER_MATTER_PROBLEMS", "EOC_FIX_XEDRA_EVOLVED_PROBLEMS" ] } diff --git a/data/mods/Sky_Island/mod_interactions/mindovermatter/eocs_healing.json b/data/mods/Sky_Island/mod_interactions/mindovermatter/eocs_healing.json index d2618532bddc5..a91e619ef6cbc 100644 --- a/data/mods/Sky_Island/mod_interactions/mindovermatter/eocs_healing.json +++ b/data/mods/Sky_Island/mod_interactions/mindovermatter/eocs_healing.json @@ -4,37 +4,41 @@ "id": "EOC_FIX_MIND_OVER_MATTER_PROBLEMS", "effect": [ { "math": [ "u_vitamin('vitamin_psionic_drain') = 0" ] }, - { "u_lose_effect": "psi_nether_attention" }, - { "u_lose_effect": "effect_nether_attunement_raiser" }, - { "u_lose_effect": "effect_nether_attunement_attenuation" }, - { "u_lose_effect": "effect_nether_attunement_feedback" }, - { "u_lose_effect": "psi_blind" }, - { "u_lose_effect": "psi_dazed" }, - { "u_lose_effect": "psi_deaf" }, - { "u_lose_effect": "effect_photokinetic_illuminate_enemy" }, - { "u_lose_effect": "effect_photokinetic_illumination" }, - { "u_lose_effect": "effect_riftwalker_teleport" }, - { "u_lose_effect": "effect_teleporting_lock" }, - { "u_lose_effect": "effect_vitakinetic_health_down" }, - { "u_lose_effect": "effect_vitakinetic_healing_down" }, - { "u_lose_effect": "effect_vitakinetic_healing_down_super" }, - { "u_lose_effect": "psi_vitakinetic_degeneration" }, - { "u_lose_effect": "psionic_overload" }, - { "u_lose_effect": "effect_psi_null_unbound" }, - { "u_lose_effect": "effect_biokin_overload" }, - { "u_lose_effect": "blind_clair_overload" }, - { "u_lose_effect": "deaf_clair_overload" }, - { "u_lose_effect": "effect_electrokin_overload" }, - { "u_lose_effect": "effect_photokin_lumination_overload" }, - { "u_lose_effect": "effect_photokin_myopia_overload" }, - { "u_lose_effect": "blind_photokin_overload" }, - { "u_lose_effect": "effect_pyrokin_overload" }, - { "u_lose_effect": "effect_pyrokin_fever_burning" }, - { "u_lose_effect": "effect_portal_storm_teleport" }, - { "u_lose_effect": "effect_teleporter_overload" }, - { "u_lose_effect": "effect_psi_teleport_lock" }, - { "u_lose_effect": "effect_telekin_overload" }, - { "u_lose_effect": "effect_vitakin_overload" } + { + "u_lose_effect": [ + "psi_nether_attention", + "effect_nether_attunement_raiser", + "effect_nether_attunement_attenuation", + "effect_nether_attunement_feedback", + "psi_blind", + "psi_dazed", + "psi_deaf", + "effect_photokinetic_illuminate_enemy", + "effect_photokinetic_illumination", + "effect_riftwalker_teleport", + "effect_teleporting_lock", + "effect_vitakinetic_health_down", + "effect_vitakinetic_healing_down", + "effect_vitakinetic_healing_down_super", + "psi_vitakinetic_degeneration", + "psionic_overload", + "effect_psi_null_unbound", + "effect_biokin_overload", + "blind_clair_overload", + "deaf_clair_overload", + "effect_electrokin_overload", + "effect_photokin_lumination_overload", + "effect_photokin_myopia_overload", + "blind_photokin_overload", + "effect_pyrokin_overload", + "effect_pyrokin_fever_burning", + "effect_portal_storm_teleport", + "effect_teleporter_overload", + "effect_psi_teleport_lock", + "effect_telekin_overload", + "effect_vitakin_overload" + ] + } ] } ] diff --git a/data/mods/Sky_Island/mod_interactions/xedra_evolved/eocs_healing.json b/data/mods/Sky_Island/mod_interactions/xedra_evolved/eocs_healing.json index ae0ddd831e516..003e6302cf7ae 100644 --- a/data/mods/Sky_Island/mod_interactions/xedra_evolved/eocs_healing.json +++ b/data/mods/Sky_Island/mod_interactions/xedra_evolved/eocs_healing.json @@ -14,13 +14,17 @@ "if": { "and": [ { "u_has_trait": "VAMPIRE" }, { "math": [ "u_vitamin('human_blood_vitamin') <= -4800" ] } ] }, "then": { "math": [ "u_vitamin('human_blood_vitamin')", "=", "0" ] } }, - { "u_lose_effect": "blood_spiders" }, - { "u_lose_effect": "visuals" }, - { "u_lose_effect": "effect_dread_weight" }, - { "u_lose_effect": "poisoned_blood" }, - { "u_lose_effect": "poisoned_blood2" }, - { "u_lose_effect": "effect_broke_fae_ban" }, - { "u_lose_effect": "effect_evil_eye" } + { + "u_lose_effect": [ + "blood_spiders", + "visuals", + "effect_dread_weight", + "poisoned_blood", + "poisoned_blood2", + "effect_broke_fae_ban", + "effect_evil_eye" + ] + } ] } ] diff --git a/data/mods/Xedra_Evolved/eocs/chronomancer_eocs.json b/data/mods/Xedra_Evolved/eocs/chronomancer_eocs.json index 67c27e599e861..9f9280ee23752 100644 --- a/data/mods/Xedra_Evolved/eocs/chronomancer_eocs.json +++ b/data/mods/Xedra_Evolved/eocs/chronomancer_eocs.json @@ -317,8 +317,7 @@ "type": "effect_on_condition", "id": "EOC_XEDRA_CHRONOMANCER_MEDITATE_EFFFECT_REMOVE", "effect": [ - { "u_lose_effect": "effect_xedra_rewrite_wound_causality" }, - { "u_lose_effect": "effect_xedra_rewrite_equipment_causality" }, + { "u_lose_effect": [ "effect_xedra_rewrite_wound_causality", "effect_xedra_rewrite_equipment_causality" ] }, { "u_message": "You finish your meditations.", "type": "good" } ] }, @@ -461,11 +460,15 @@ }, "then": [ { "u_message": "Your chronomantic powers destabilize and you lose their effects!" }, - { "u_lose_effect": "effect_xedra_chronomancer_chronal_accel" }, - { "u_lose_effect": "effect_xedra_chronomancer_destabilizing_strikes" }, - { "u_lose_effect": "effect_xedra_chronomancer_stabilize_timeline" }, - { "u_lose_effect": "effect_xedra_chronomancer_reverse_entropy" }, - { "u_lose_effect": "effect_xedra_chronomancer_stable_timeloop" } + { + "u_lose_effect": [ + "effect_xedra_chronomancer_chronal_accel", + "effect_xedra_chronomancer_destabilizing_strikes", + "effect_xedra_chronomancer_stabilize_timeline", + "effect_xedra_chronomancer_reverse_entropy", + "effect_xedra_chronomancer_stable_timeloop" + ] + } ] }, { "run_eocs": "EOC_XEDRA_CHRONOMANCER_UNSTABLE_POWERS", "time_in_future": [ "30 minutes", "2 hours" ] } diff --git a/data/mods/Xedra_Evolved/eocs/magic_weather_control.json b/data/mods/Xedra_Evolved/eocs/magic_weather_control.json index e3207dd74d8e1..b048f69af47d1 100644 --- a/data/mods/Xedra_Evolved/eocs/magic_weather_control.json +++ b/data/mods/Xedra_Evolved/eocs/magic_weather_control.json @@ -166,8 +166,7 @@ "id": "EOC_WEATHER_CONTROL_ABOVE_FREEZING_DOWNGRADE", "condition": { "not": { "u_has_effect": "effect_controlling_weather" } }, "effect": [ - { "u_lose_effect": "effect_controlling_weather_rains" }, - { "u_lose_effect": "effect_controlling_weather_rainstorm" }, + { "u_lose_effect": [ "effect_controlling_weather_rains", "effect_controlling_weather_rainstorm" ] }, { "if": { "is_weather": "magic_weather_light_drizzle" }, "then": { "run_eocs": "EOC_WEATHER_CONTROL_LIGHT_DRIZZLE_TO_NOTHING" }, diff --git a/data/mods/Xedra_Evolved/mutations/paraclesians/arvore_eocs.json b/data/mods/Xedra_Evolved/mutations/paraclesians/arvore_eocs.json index 2dfbf9aa872b3..00904e83b73f1 100644 --- a/data/mods/Xedra_Evolved/mutations/paraclesians/arvore_eocs.json +++ b/data/mods/Xedra_Evolved/mutations/paraclesians/arvore_eocs.json @@ -545,22 +545,26 @@ { "math": [ "u_vitamin('instability') = 0" ] }, { "math": [ "u_pain() = 0" ] }, { "math": [ "u_val('rad') = 0" ] }, - { "u_lose_effect": "corroding" }, - { "u_lose_effect": "onfire" }, - { "u_lose_effect": "dazed" }, - { "u_lose_effect": "stunned" }, - { "u_lose_effect": "venom_blind" }, - { "u_lose_effect": "formication" }, - { "u_lose_effect": "blisters" }, - { "u_lose_effect": "frostbite" }, - { "u_lose_effect": "frostbite_recovery" }, - { "u_lose_effect": "wet" }, - { "u_lose_effect": "slimed" }, - { "u_lose_effect": "migo_atmosphere" }, - { "u_lose_effect": "fetid_goop" }, - { "u_lose_effect": "sap" }, - { "u_lose_effect": "nausea" }, - { "u_lose_effect": "bleed" } + { + "u_lose_effect": [ + "corroding", + "onfire", + "dazed", + "stunned", + "venom_blind", + "formication", + "blisters", + "frostbite", + "frostbite_recovery", + "wet", + "slimed", + "migo_atmosphere", + "fetid_goop", + "sap", + "nausea", + "bleed" + ] + } ] }, { diff --git a/data/mods/Xedra_Evolved/mutations/paraclesians/sylph_eocs.json b/data/mods/Xedra_Evolved/mutations/paraclesians/sylph_eocs.json index 25dd952b19327..92e1c2d918bdf 100644 --- a/data/mods/Xedra_Evolved/mutations/paraclesians/sylph_eocs.json +++ b/data/mods/Xedra_Evolved/mutations/paraclesians/sylph_eocs.json @@ -115,8 +115,7 @@ ], "false_effect": [ { "u_message": "You do not have enough mana to fly!", "type": "bad" }, - { "u_lose_effect": "effect_sylph_levitation" }, - { "u_lose_effect": "effect_sylph_climb_flying" } + { "u_lose_effect": [ "effect_sylph_levitation", "effect_sylph_climb_flying" ] } ] }, { @@ -136,18 +135,13 @@ "effect": [ { "math": [ "u_val('mana')", "-=", "10" ] } ], "false_effect": [ { "u_message": "You do not have enough mana to maintain your cloud body!", "type": "bad" }, - { "u_lose_effect": "incorporeal" }, - { "u_lose_effect": "effect_sylph_cloud_body" } + { "u_lose_effect": [ "incorporeal", "effect_sylph_cloud_body" ] } ] }, { "type": "effect_on_condition", "id": "EOC_SYLPH_CLOUD_FORM_OFF", - "effect": [ - { "u_lose_effect": "effect_sylph_cloud_body" }, - { "u_lose_effect": "incorporeal" }, - { "u_lose_trait": "SYLPH_CLOUD_FORM_APPEARANCE" } - ] + "effect": [ { "u_lose_effect": [ "effect_sylph_cloud_body", "incorporeal" ] }, { "u_lose_trait": "SYLPH_CLOUD_FORM_APPEARANCE" } ] }, { "type": "effect_on_condition", diff --git a/data/mods/Xedra_Evolved/mutations/playable_changeling_eocs.json b/data/mods/Xedra_Evolved/mutations/playable_changeling_eocs.json index c02a5ee5b6785..fde3e4084ce32 100644 --- a/data/mods/Xedra_Evolved/mutations/playable_changeling_eocs.json +++ b/data/mods/Xedra_Evolved/mutations/playable_changeling_eocs.json @@ -187,8 +187,7 @@ "type": "effect_on_condition", "id": "EOC_CHANGELING_EFFECTS_REMOVED_LOSE_EFFECTS", "effect": [ - { "u_lose_effect": "effect_changeling_invisibility" }, - { "u_lose_effect": "effect_changeling_right_of_passage" }, + { "u_lose_effect": [ "effect_changeling_invisibility", "effect_changeling_right_of_passage" ] }, { "u_lose_trait": "CHANGELING_DISGUISE_AS_NATURE_BUSH" }, { "u_lose_trait": "CHANGELING_DISGUISE_AS_NATURE_TREE" }, { "u_lose_trait": "CHANGELING_DISGUISE_AS_NATURE_POND" }, @@ -1699,8 +1698,7 @@ "condition": { "math": [ "magic_weather_lightning == 1" ] }, "effect": [ { "math": [ "u_weather_change_limit = 0" ] }, - { "u_lose_effect": "effect_controlling_weather" }, - { "u_lose_effect": "effect_controlling_weather_lightningstorm" } + { "u_lose_effect": [ "effect_controlling_weather", "effect_controlling_weather_lightningstorm" ] } ] }, { diff --git a/data/mods/Xedra_Evolved/mutations/vampire_trait_eocs.json b/data/mods/Xedra_Evolved/mutations/vampire_trait_eocs.json index 724f1a55432e8..d13d6f2ac3c0a 100644 --- a/data/mods/Xedra_Evolved/mutations/vampire_trait_eocs.json +++ b/data/mods/Xedra_Evolved/mutations/vampire_trait_eocs.json @@ -134,8 +134,7 @@ "condition": { "u_has_effect": "eyegleam" }, "effect": [ { "u_message": "Your eyes lose their reddish glint as the darkness rolls back in.", "type": "neutral" }, - { "u_lose_effect": "eyegleam" }, - { "u_lose_effect": "eyegleam_craft_in_darkness" } + { "u_lose_effect": [ "eyegleam", "eyegleam_craft_in_darkness" ] } ] } ] @@ -175,8 +174,7 @@ ], "false_effect": [ { "u_message": "You don't have enough blood to maintain your gleaming eyes.", "type": "bad" }, - { "u_lose_effect": "eyegleam" }, - { "u_lose_effect": "eyegleam_craft_in_darkness" }, + { "u_lose_effect": [ "eyegleam", "eyegleam_craft_in_darkness" ] }, { "u_deactivate_trait": "EYEGLEAM" } ] } @@ -420,12 +418,7 @@ { "math": [ "u_vitamin('human_blood_vitamin')", "-=", "500" ] }, { "u_add_effect": "blood_weave", "duration": "PERMANENT" }, { "u_message": "You hold tightly to your blood, preventing it from leaving your body.", "type": "good" }, - { "u_lose_effect": "bleed", "target_part": "torso" }, - { "u_lose_effect": "bleed", "target_part": "leg_l" }, - { "u_lose_effect": "bleed", "target_part": "leg_r" }, - { "u_lose_effect": "bleed", "target_part": "head" }, - { "u_lose_effect": "bleed", "target_part": "arm_l" }, - { "u_lose_effect": "bleed", "target_part": "arm_r" }, + { "u_lose_effect": "bleed", "target_part": "ALL" }, { "run_eocs": [ "EOC_COAGULANTWEAVE_maintenance" ], "time_in_future": { @@ -1186,8 +1179,7 @@ "condition": { "u_has_trait": "VAMPIRE_MIST_FORM_TRAITS" }, "effect": [ { "u_message": "You reconstitute yourself from the billowing mists.", "type": "neutral" }, - { "u_lose_effect": "effect_vampire_mist_form" }, - { "u_lose_effect": "incorporeal" }, + { "u_lose_effect": [ "effect_vampire_mist_form", "incorporeal" ] }, { "u_lose_trait": "VAMPIRE_MIST_FORM_TRAITS" }, { "math": [ "u_spell_level('vampire_mist_form_pass_through_doors_and_windows') = -1" ] } ] @@ -1435,23 +1427,27 @@ { "math": [ "u_hp('arm_r') = max( u_hp('arm_r'), 30)" ] }, { "math": [ "u_hp('leg_l') = max( u_hp('leg_l'), 30)" ] }, { "math": [ "u_hp('leg_r') = max( u_hp('leg_r'), 30)" ] }, - { "u_lose_effect": "downed" }, - { "u_lose_effect": "stunned" }, - { "u_lose_effect": "corroding" }, - { "u_lose_effect": "onfire" }, - { "u_lose_effect": "dazed" }, - { "u_lose_effect": "venom_blind" }, - { "u_lose_effect": "formication" }, - { "u_lose_effect": "blisters" }, - { "u_lose_effect": "frostbite" }, - { "u_lose_effect": "frostbite_recovery" }, - { "u_lose_effect": "wet" }, - { "u_lose_effect": "slimed" }, - { "u_lose_effect": "migo_atmosphere" }, - { "u_lose_effect": "fetid_goop" }, - { "u_lose_effect": "sap" }, - { "u_lose_effect": "nausea" }, - { "u_lose_effect": "bleed" }, + { + "u_lose_effect": [ + "downed", + "stunned", + "corroding", + "onfire", + "dazed", + "venom_blind", + "formication", + "blisters", + "frostbite", + "frostbite_recovery", + "wet", + "slimed", + "migo_atmosphere", + "fetid_goop", + "sap", + "nausea", + "bleed" + ] + }, { "math": [ "u_pain() = 0" ] }, { "math": [ "u_vitamin('redcells') = 0" ] }, { "math": [ "u_vitamin('blood') = 0" ] }, diff --git a/data/mods/Xedra_Evolved/mutations/xe_lilin_trait_eocs.json b/data/mods/Xedra_Evolved/mutations/xe_lilin_trait_eocs.json index b031986768d15..0b2e131786f18 100644 --- a/data/mods/Xedra_Evolved/mutations/xe_lilin_trait_eocs.json +++ b/data/mods/Xedra_Evolved/mutations/xe_lilin_trait_eocs.json @@ -520,18 +520,22 @@ { "math": [ "u_vitamin('redcells') = 0" ] }, { "math": [ "u_vitamin('bad_food') = 0" ] }, { "math": [ "u_vitamin('blood') = 0" ] }, - { "u_lose_effect": "corroding" }, - { "u_lose_effect": "dazed" }, - { "u_lose_effect": "downed" }, - { "u_lose_effect": "stunned" }, - { "u_lose_effect": "venom_blind" }, - { "u_lose_effect": "sap" }, - { "u_lose_effect": "staggered_character" }, - { "u_lose_effect": "nausea" }, - { "u_lose_effect": "bleed" }, - { "u_lose_effect": "blind" }, - { "u_lose_effect": "deaf" }, - { "u_lose_effect": "grabbed" }, + { + "u_lose_effect": [ + "corroding", + "dazed", + "downed", + "stunned", + "venom_blind", + "sap", + "staggered_character", + "nausea", + "bleed", + "blind", + "deaf", + "grabbed" + ] + }, { "u_add_effect": "lilit_prevent_death_escape", "duration": 15 }, { "u_add_effect": "lilit_prevent_death_cooldown", "duration": 300 }, { "math": [ "u_vitamin('lilin_ruach_vitamin')", "+=", "360 * lilin_has_ruach_efficiency()" ] }, diff --git a/data/mods/Xedra_Evolved/spells/lilin_spell_eocs.json b/data/mods/Xedra_Evolved/spells/lilin_spell_eocs.json index 56f4cc4dbd8f8..10c75e3b31c2c 100644 --- a/data/mods/Xedra_Evolved/spells/lilin_spell_eocs.json +++ b/data/mods/Xedra_Evolved/spells/lilin_spell_eocs.json @@ -540,7 +540,7 @@ "eoc_type": "EVENT", "required_event": "character_takes_damage", "condition": { "and": [ { "u_has_effect": "stunned" }, { "u_has_effect": "effect_lilin_mesmerize_tracker" } ] }, - "effect": [ { "u_lose_effect": "effect_lilin_mesmerize_tracker" }, { "u_lose_effect": "stunned" } ] + "effect": [ { "u_lose_effect": [ "effect_lilin_mesmerize_tracker", "stunned" ] } ] }, { "type": "effect_on_condition", @@ -548,7 +548,7 @@ "eoc_type": "EVENT", "required_event": "monster_takes_damage", "condition": { "and": [ { "u_has_effect": "stunned" }, { "u_has_effect": "effect_lilin_mesmerize_tracker" } ] }, - "effect": [ { "u_lose_effect": "effect_lilin_mesmerize_tracker" }, { "u_lose_effect": "stunned" } ] + "effect": [ { "u_lose_effect": [ "effect_lilin_mesmerize_tracker", "stunned" ] } ] }, { "type": "effect_on_condition", diff --git a/doc/JSON/EFFECT_ON_CONDITION.md b/doc/JSON/EFFECT_ON_CONDITION.md index c532b8c8b94e6..4486f5aed51b0 100644 --- a/doc/JSON/EFFECT_ON_CONDITION.md +++ b/doc/JSON/EFFECT_ON_CONDITION.md @@ -2870,7 +2870,7 @@ Some effect would be applied on you or NPC | Syntax | Optionality | Value | Info | | --- | --- | --- | --- | | "u_add_effect" / "npc_add_effect" | **mandatory** | string or [variable object](#variable-object) | id of effect to give | -| "duration" | optional | int, duration or [variable object](#variable-object) | 0 by default; length of the effect; both int (`"duration": 60`), and duration string (`"duration": "1 m"`) works; `PERMANENT` can be used to give a permanent effect | +| "duration" | **mandatory** | int, duration or [variable object](#variable-object) | length of the effect; both int (`"duration": 60`), and duration string (`"duration": "1 m"`) works; `PERMANENT` can be used to give a permanent effect | | "target_part" | optional | string or [variable object](#variable-object) | default is "whole body"; if used, only specified body part would be used. `RANDOM` can be used to pick a random body part | | "intensity" | optional | int, float or [variable object](#variable-object) | default 0; intensity of the effect | | "force_bool" | optional | boolean | default false; if true, all immunities would be ignored | @@ -2989,8 +2989,8 @@ Remove effect from character or NPC, if it has one | Syntax | Optionality | Value | Info | | --- | --- | --- | --- | -| "u_lose_effect" / "npc_lose_effect" | **mandatory** | string or [variable object](#variable-object) | id of effect to be removed; if character or NPC has no such effect, nothing happens | -| "target_part" | optional | string or [variable object](#variable-object) | default is "whole body"; if used, only specified body part would be used. `RANDOM` can be used to pick a random body part | +| "u_lose_effect" / "npc_lose_effect" | **mandatory** | string, [variable object](#variable-object), or array of both | id of effect or effects to be removed; if character or NPC has no such effect, nothing happens | +| "target_part" | optional | string or [variable object](#variable-object) | default is "whole body"; if used, only specified body part would be used. `ALL` can be used to remove effect from all bodyparts talker has | ##### Valid talkers: @@ -3009,11 +3009,21 @@ Removes `bleed` effect from player's head: { "u_lose_effect": "bleed", "target_part": "head" } ``` +Removes `bleed` effect from all bodyparts: +```json +{ "u_lose_effect": "bleed", "target_part": "ALL" } +``` + Removes effect, stored in `effect_id` context value, from the player: ```json { "u_lose_effect": { "context_val": "effect_id" } } ``` +Removes `infection`, `downed` and `winded` effects from player: +```json +{ "u_lose_effect": [ "infection", "downed", "winded" ] } +``` + #### `u_lose_trait`, `npc_lose_trait` Character or NPC got trait or mutation removed, if it has one diff --git a/doc/JSON/JSON_INFO.md b/doc/JSON/JSON_INFO.md index ffb9b4319beb6..200d16fe6f9df 100644 --- a/doc/JSON/JSON_INFO.md +++ b/doc/JSON/JSON_INFO.md @@ -2020,6 +2020,7 @@ The following properties (mandatory, except if noted otherwise) are supported: "CBMs": [ "bio_fuel_cell_blood" ], // (optional) Array of starting implanted CMBs "traits": [ "PROF_CHURL", "ILLITERATE" ], // (optional) Array of starting traits/mutations. For further information, see mutations.json and MUTATIONS.md. Note: "trait" is also supported, used for a single trait/mutation ID (legacy!) "requirement": "achievement_survive_28_days", // (optional) String of an achievement ID required to unlock this profession + "effect_on_conditions": [ "scenario_assassin_conv" ], // (optional) eoc id, inline eoc, or multiple of them, that would run when scenario starts "spells": [ // (optional) Array of starting spell IDs the character knows upon creation. For further information, see MAGIC.md { "id": "magic_missile", "level": 4 }, { "id": "summon_undead", "level": 5 }, diff --git a/src/effect_on_condition.cpp b/src/effect_on_condition.cpp index b0f1c860d98a9..023a28fd18679 100644 --- a/src/effect_on_condition.cpp +++ b/src/effect_on_condition.cpp @@ -24,6 +24,7 @@ #include "mod_tracker.h" #include "npc.h" #include "output.h" +#include "profession.h" #include "scenario.h" #include "string_formatter.h" #include "talker.h" @@ -39,7 +40,9 @@ namespace io switch ( data ) { case eoc_type::ACTIVATION: return "ACTIVATION"; case eoc_type::RECURRING: return "RECURRING"; + // Why we need SCENARIO_SPECIFIC / PROFESSION_SPECIFIC? they are no different from ACTIVATION case eoc_type::SCENARIO_SPECIFIC: return "SCENARIO_SPECIFIC"; + case eoc_type::PROFESSION_SPECIFIC: return "PROFESSION_SPECIFIC"; case eoc_type::AVATAR_DEATH: return "AVATAR_DEATH"; case eoc_type::NPC_DEATH: return "NPC_DEATH"; case eoc_type::PREVENT_DEATH: return "PREVENT_DEATH"; @@ -146,6 +149,17 @@ void effect_on_conditions::load_new_character( Character &you ) you.queued_effect_on_conditions.push( new_eoc ); } } + + if( you.get_profession() ) { + for( const effect_on_condition_id &eoc_id : you.get_profession()->get_eocs() ) { + effect_on_condition eoc = eoc_id.obj(); + if( eoc.type == eoc_type::PROFESSION_SPECIFIC && ( is_avatar || eoc.run_for_npcs ) ) { + queued_eoc new_eoc = queued_eoc{ eoc.id, calendar::turn_zero, {} }; + you.queued_effect_on_conditions.push( new_eoc ); + } + } + } + for( const effect_on_condition &eoc : effect_on_conditions::get_all() ) { if( eoc.type == eoc_type::RECURRING && ( ( is_avatar && eoc.global ) || !eoc.global ) ) { dialogue d( get_talker_for( you ), nullptr ); diff --git a/src/effect_on_condition.h b/src/effect_on_condition.h index c3b974928e45f..a954f6d0a71eb 100644 --- a/src/effect_on_condition.h +++ b/src/effect_on_condition.h @@ -30,6 +30,7 @@ enum eoc_type { ACTIVATION, RECURRING, SCENARIO_SPECIFIC, + PROFESSION_SPECIFIC, AVATAR_DEATH, NPC_DEATH, PREVENT_DEATH, diff --git a/src/npctalk.cpp b/src/npctalk.cpp index aa3c443a54adb..42f109980eddb 100644 --- a/src/npctalk.cpp +++ b/src/npctalk.cpp @@ -3367,7 +3367,14 @@ talk_effect_fun_t::func f_add_effect( const JsonObject &jo, std::string_view mem talk_effect_fun_t::func f_remove_effect( const JsonObject &jo, std::string_view member, const std::string_view, bool is_npc ) { - str_or_var old_effect = get_str_or_var( jo.get_member( member ), member, true ); + std::vector old_effects; + if( jo.has_string( member ) ) { + old_effects.emplace_back( get_str_or_var( jo.get_member( member ), member ) ); + } else if( jo.has_array( member ) ) { + for( JsonValue jv : jo.get_array( member ) ) { + old_effects.emplace_back( get_str_or_var( jv, member ) ); + } + } str_or_var target; if( jo.has_member( "target_part" ) ) { @@ -3376,8 +3383,21 @@ talk_effect_fun_t::func f_remove_effect( const JsonObject &jo, std::string_view target.str_val = "bp_null"; } - return [is_npc, old_effect, target]( dialogue const & d ) { - d.actor( is_npc )->remove_effect( efftype_id( old_effect.evaluate( d ) ), target.evaluate( d ) ); + return [is_npc, old_effects, target]( dialogue const & d ) { + if( target.evaluate( d ) == "ALL" ) { + std::vector all_bprts = d.actor( is_npc )->get_all_body_parts( + get_body_part_flags::none ); + all_bprts.emplace_back( "bp_null" ); + for( const str_or_var &old_effect : old_effects ) { + for( bodypart_id bp : all_bprts ) { + d.actor( is_npc )->remove_effect( efftype_id( old_effect.evaluate( d ) ), bp.id().c_str() ); + } + } + } else { + for( const str_or_var &old_effect : old_effects ) { + d.actor( is_npc )->remove_effect( efftype_id( old_effect.evaluate( d ) ), target.evaluate( d ) ); + } + } }; } diff --git a/src/profession.cpp b/src/profession.cpp index 7356e1e01349e..21adb99253f3c 100644 --- a/src/profession.cpp +++ b/src/profession.cpp @@ -13,6 +13,7 @@ #include "avatar.h" #include "calendar.h" #include "debug.h" +#include "effect_on_condition.h" #include "flag.h" #include "generic_factory.h" #include "item.h" @@ -279,6 +280,12 @@ void profession::load( const JsonObject &jo, const std::string_view ) } } + if( jo.has_member( "effect_on_conditions" ) ) { + for( JsonValue jv : jo.get_array( "effect_on_conditions" ) ) { + effect_on_conditions.push_back( effect_on_conditions::load_inline_eoc( jv, "" ) ); + } + } + mandatory( jo, was_loaded, "points", _point_cost ); if( !was_loaded || jo.has_member( "items" ) ) { @@ -741,6 +748,11 @@ void profession::learn_spells( avatar &you ) const } } +std::vector profession::get_eocs() const +{ + return effect_on_conditions; +} + // item_substitution stuff: void profession::load_item_substitutions( const JsonObject &jo ) diff --git a/src/profession.h b/src/profession.h index 7f1e70baa84d9..fbc06d724e81c 100644 --- a/src/profession.h +++ b/src/profession.h @@ -82,6 +82,7 @@ class profession vproto_id _starting_vehicle = vproto_id::NULL_ID(); // the int is what level the spell starts at std::map _starting_spells; + std::vector effect_on_conditions; std::set flags; // flags for some special properties of the profession StartingSkillList _starting_skills; std::vector _missions; // starting missions for profession @@ -138,7 +139,7 @@ class profession std::map spells() const; void learn_spells( avatar &you ) const; - + std::vector get_eocs() const; //returns the profession id profession_id get_profession_id() const;