Added a battle config for the Soul Dew

This commit is contained in:
LOuroboros 2021-11-04 17:18:26 -03:00
parent a30573f317
commit 671cbabc3d
2 changed files with 5 additions and 1 deletions

View file

@ -166,6 +166,7 @@
#define B_X_ITEMS_BUFF GEN_7 // In Gen7+, the X Items raise a stat by 2 stages instead of 1.
#define B_MENTAL_HERB GEN_5 // In Gen5+, the Mental Herb cures Infatuation, Taunt, Encore, Torment, Heal Block, and Disable
#define B_TRAINERS_KNOCK_OFF_ITEMS TRUE // If TRUE, trainers can steal/swap your items (non-berries are restored after battle). In vanilla games trainers cannot steal items.
#define B_SOUL_DEW_BOOST GEN_7 // In Gens3-6, Soul Dew boosts the power of Lati@s' stats. In Gen7+ it boosts the power of their Psychic and Dragon type moves instead.
// Flag settings
// To use the following features in scripting, replace the 0s with the flag ID you're assigning it to.

View file

@ -8059,7 +8059,10 @@ static u32 CalcMoveBasePowerAfterModifiers(u16 move, u8 battlerAtk, u8 battlerDe
MulModifier(&modifier, holdEffectModifier);
break;
case HOLD_EFFECT_SOUL_DEW:
if ((gBattleMons[battlerAtk].species == SPECIES_LATIAS || gBattleMons[battlerAtk].species == SPECIES_LATIOS) && !(gBattleTypeFlags & BATTLE_TYPE_FRONTIER))
if (((gBattleMons[battlerAtk].species == SPECIES_LATIAS || gBattleMons[battlerAtk].species == SPECIES_LATIOS)
&& !(gBattleTypeFlags & BATTLE_TYPE_FRONTIER) && B_SOUL_DEW_BOOST <= GEN_6)
|| ((gBattleMons[battlerAtk].species == SPECIES_LATIAS || gBattleMons[battlerAtk].species == SPECIES_LATIOS)
&& (moveType == TYPE_PSYCHIC || moveType == TYPE_DRAGON) && B_SOUL_DEW_BOOST >= GEN_7))
MulModifier(&modifier, holdEffectModifier);
break;
case HOLD_EFFECT_GEMS: