Skip to content

Commit 2851bdb

Browse files
[MoM] Further concentration updates (CleverRaven#75851)
* Initial commit * Buff master concentration * Remove duplicates * Reduce smoke penalties
1 parent 2db2a2e commit 2851bdb

File tree

3 files changed

+16
-42
lines changed

3 files changed

+16
-42
lines changed

data/mods/MindOverMatter/effectoncondition/eoc_misc.json

Lines changed: 5 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -114,44 +114,6 @@
114114
{ "run_eocs": [ "EOC_END_PSI_POWERS_MAINTAINED" ] }
115115
]
116116
},
117-
{
118-
"type": "effect_on_condition",
119-
"id": "EOC_PSIONICS_DAZED_ENDS_POWERS",
120-
"eoc_type": "EVENT",
121-
"required_event": "character_gains_effect",
122-
"condition": {
123-
"and": [
124-
{
125-
"or": [
126-
{ "compare_string": [ "dazed", { "context_val": "effect" } ] },
127-
{ "compare_string": [ "psi_dazed", { "context_val": "effect" } ] },
128-
{ "compare_string": [ "psi_dazed_zap", { "context_val": "effect" } ] },
129-
{ "compare_string": [ "downed", { "context_val": "effect" } ] }
130-
]
131-
},
132-
{ "math": [ "u_vitamin('vitamin_maintained_powers')", ">=", "1" ] }
133-
]
134-
},
135-
"effect": [
136-
{
137-
"run_eocs": [
138-
{
139-
"id": "EOC_PSIONICS_DAZED_ENDS_POWERS_2",
140-
"condition": {
141-
"roll_contested": { "math": [ "(u_val('intelligence') / 2) + u_skill('metaphysics') + concentration_trait_bonuses()" ] },
142-
"difficulty": 20,
143-
"die_size": 15
144-
},
145-
"effect": [ ],
146-
"false_effect": [
147-
{ "u_message": "Your head is swimming. You can no longer maintain your powers!", "type": "bad" },
148-
{ "run_eocs": [ "EOC_END_PSI_POWERS_MAINTAINED" ] }
149-
]
150-
}
151-
]
152-
}
153-
]
154-
},
155117
{
156118
"type": "effect_on_condition",
157119
"id": "EOC_PSIONICS_WEARINESS_ENDS_POWERS",
@@ -216,7 +178,11 @@
216178
{ "compare_string": [ "zapped", { "context_val": "effect" } ] },
217179
{ "compare_string": [ "effect_psi_reduced_breathing", { "context_val": "effect" } ] },
218180
{ "compare_string": [ "effect_psi_null", { "context_val": "effect" } ] },
219-
{ "compare_string": [ "effect_psi_null_unbound", { "context_val": "effect" } ] }
181+
{ "compare_string": [ "effect_psi_null_unbound", { "context_val": "effect" } ] },
182+
{ "compare_string": [ "dazed", { "context_val": "effect" } ] },
183+
{ "compare_string": [ "psi_dazed", { "context_val": "effect" } ] },
184+
{ "compare_string": [ "psi_dazed_zap", { "context_val": "effect" } ] },
185+
{ "compare_string": [ "downed", { "context_val": "effect" } ] }
220186
]
221187
},
222188
{ "math": [ "u_vitamin('vitamin_maintained_powers')", ">=", "1" ] }

data/mods/MindOverMatter/effectoncondition/eoc_on_power_use_events.json

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -568,9 +568,16 @@
568568
"id": "EOC_POWER_MAINTENANCE_CONCENTRATION_CHECK",
569569
"condition": {
570570
"and": [
571-
{ "math": [ "u_vitamin('vitamin_maintained_powers')", ">", "concentration_calculations()" ] },
571+
{ "math": [ "u_vitamin('vitamin_maintained_powers')", ">=", "concentration_calculations()" ] },
572572
{
573-
"x_in_y_chance": { "x": { "math": [ "(u_vitamin('vitamin_maintained_powers') / max(concentration_calculations(),1)) * 5" ] }, "y": 100 }
573+
"x_in_y_chance": {
574+
"x": {
575+
"math": [
576+
"((u_vitamin('vitamin_maintained_powers') / max(concentration_calculations(),1)) * 5) + (clamp(concentration_calculations(), -10, 0) * -10)"
577+
]
578+
},
579+
"y": 100
580+
}
574581
}
575582
]
576583
},

data/mods/MindOverMatter/jmath.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,8 @@
5151
"type": "jmath_function",
5252
"id": "concentration_trait_bonuses",
5353
"num_args": 0,
54-
"return": "(u_has_trait('CONCENTRATION_GOOD')) + (u_has_trait('CONCENTRATION_BAD') ? -1 : 0) + (u_has_trait('INT_ALPHA')) + (u_has_trait('NOMAD2') ? -1 : 0) + (u_has_trait('NOMAD3') ? -1 : 0) + (u_has_trait('CONCENTRATION_DEBUG') ? 50 : 0) + (u_has_proficiency('prof_concentration_basic')) + (u_has_proficiency('prof_concentration_intermediate')) + (u_has_proficiency('prof_concentration_master')) + (u_effect_intensity('hallu') > 0 ? -1 : 0) + (u_effect_intensity('winded') > 0 ? -2 : 0) + (u_effect_intensity('nausea') > 0 ? -1 : 0) + (u_effect_intensity('nausea') > 3 ? -1 : 0) + (u_effect_intensity('cold') > 1 ? -1 : 0) + (u_effect_intensity('hot') > 1 ? -1 : 0) + (u_effect_intensity('asthma') > 0 ? -3 : 0) + (u_effect_intensity('datura') > 0 ? -3 : 0)"
54+
"//": "Effects with an intelligence penalty have not been included below to avoid double counting",
55+
"return": "(u_has_trait('CONCENTRATION_GOOD')) + (u_has_trait('CONCENTRATION_BAD') ? -1 : 0) + (u_has_trait('INT_ALPHA')) + (u_has_trait('NOMAD2') ? -1 : 0) + (u_has_trait('NOMAD3') ? -1 : 0) + (u_has_trait('CONCENTRATION_DEBUG') ? 50 : 0) + (u_has_proficiency('prof_concentration_basic')) + (u_has_proficiency('prof_concentration_intermediate')) + (u_has_proficiency('prof_concentration_master') * 2) + (u_effect_intensity('hallu') > 0 ? -1 : 0) + (u_effect_intensity('winded') > 0 ? -2 : 0) + (u_effect_intensity('nausea') > 0 ? -1 : 0) + (u_effect_intensity('nausea') > 3 ? -1 : 0) + (u_effect_intensity('cold') > 1 ? -1 : 0) + (u_effect_intensity('hot') > 1 ? -1 : 0) + (u_effect_intensity('asthma') > 0 ? -3 : 0) + (u_effect_intensity('datura') > 0 ? -3 : 0) + (u_effect_intensity('dazed') > 0 ? -2 : 0) + (u_effect_intensity('psi_dazed') > 0 ? -2 : 0) + (u_effect_intensity('psi_dazed_zap') > 0 ? -1 : 0) + (u_effect_intensity('downed') > 0 ? -2 : 0) + (u_effect_intensity('boomered') > 0 ? -1 : 0) + (u_effect_intensity('conjunctivitis') > 0 ? -1 : 0) + (u_effect_intensity('teargas') > 0 ? -3 : 0) + (u_effect_intensity('smoke_eyes') > 0 ? -1 : 0) + (u_effect_intensity('smoke_lungs') > 0 ? -2 : 0)"
5556
},
5657
{
5758
"type": "jmath_function",

0 commit comments

Comments
 (0)