From 8d6aeeff974339caa9ee287e929a16b5a78e4c97 Mon Sep 17 00:00:00 2001 From: "Standing-StormStanding-Storm git config --global user.name Standing-Storm git config --global user.name Standing-Storm" Date: Thu, 6 Feb 2025 16:57:24 -0600 Subject: [PATCH] Make sure opposite season failure has a floor --- data/mods/Xedra_Evolved/jmath.json | 33 ++++++++++++++++++++++++++---- 1 file changed, 29 insertions(+), 4 deletions(-) diff --git a/data/mods/Xedra_Evolved/jmath.json b/data/mods/Xedra_Evolved/jmath.json index 0b729caae365c..cadd9948c577f 100644 --- a/data/mods/Xedra_Evolved/jmath.json +++ b/data/mods/Xedra_Evolved/jmath.json @@ -64,25 +64,50 @@ "type": "jmath_function", "id": "xe_fey_seasonal_magick_spring_failure_chance", "num_args": 0, - "return": "(0.15 + (global_what_is_the_season == 3 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.08 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.03) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_SPRING') * 0.04) )" + "return": "global_what_is_the_season == 3 ? max(xe_fey_seasonal_magick_spring_failure_chance_actual(), 0.05) : xe_fey_seasonal_magick_spring_failure_chance_actual()" + }, + { + "type": "jmath_function", + "id": "xe_fey_seasonal_magick_spring_failure_chance_actual", + "//": "This and below separations are necessary to keep the 'You cannot go below 5% chance to fail in the opposite season' logic", + "num_args": 0, + "return": "(0.15 + (global_what_is_the_season == 3 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.09 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.06) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_SPRING') * 0.04) )" }, { "type": "jmath_function", "id": "xe_fey_seasonal_magick_summer_failure_chance", "num_args": 0, - "return": "(0.15 + (global_what_is_the_season == 4 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.08 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.03) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_SUMMER') * 0.04) )" + "return": "global_what_is_the_season == 4 ? max(xe_fey_seasonal_magick_summer_failure_chance_actual(), 0.05) : xe_fey_seasonal_magick_summer_failure_chance_actual()" + }, + { + "type": "jmath_function", + "id": "xe_fey_seasonal_magick_summer_failure_chance_actual", + "num_args": 0, + "return": "(0.15 + (global_what_is_the_season == 4 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.09 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.06) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_SUMMER') * 0.04) )" }, { "type": "jmath_function", "id": "xe_fey_seasonal_magick_autumn_failure_chance", "num_args": 0, - "return": "(0.15 + (global_what_is_the_season == 1 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.08 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.03) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_AUTUMN') * 0.04) )" + "return": "global_what_is_the_season == 1 ? max(xe_fey_seasonal_magick_autumn_failure_chance_actual(), 0.05) : xe_fey_seasonal_magick_autumn_failure_chance_actual()" + }, + { + "type": "jmath_function", + "id": "xe_fey_seasonal_magick_autumn_failure_chance_actual", + "num_args": 0, + "return": "(0.15 + (global_what_is_the_season == 1 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.09 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.06) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_AUTUMN') * 0.04) )" }, { "type": "jmath_function", "id": "xe_fey_seasonal_magick_winter_failure_chance", "num_args": 0, - "return": "(0.15 + (global_what_is_the_season == 2 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.08 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.03) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_WINTER') * 0.04) )" + "return": "global_what_is_the_season == 2 ? max(xe_fey_seasonal_magick_winter_failure_chance_actual(), 0.05) : xe_fey_seasonal_magick_winter_failure_chance_actual()" + }, + { + "type": "jmath_function", + "id": "xe_fey_seasonal_magick_winter_failure_chance_actual", + "num_args": 0, + "return": "(0.15 + (global_what_is_the_season == 2 ? 0.2 : 0 ) + (u_spell_difficulty(_spell_id) * 0.09 ) + xe_fey_magick_mana_penalty() - ( (u_skill('deduction') * 0.06) + (u_spell_count('school': 'CHANGELING_SEASONAL_MAGIC_WINTER') * 0.04) )" }, { "type": "jmath_function",