From deef09112f75f0d6de4bc32e9bb35776d42a7edc Mon Sep 17 00:00:00 2001 From: LOuroboros Date: Wed, 22 Jun 2022 08:42:31 -0300 Subject: [PATCH] Corrected usage of B_AFFECTION_MECHANICS in CalcCritChanceStage --- src/battle_script_commands.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/battle_script_commands.c b/src/battle_script_commands.c index 1d42e5511..4e238c54d 100644 --- a/src/battle_script_commands.c +++ b/src/battle_script_commands.c @@ -1892,9 +1892,11 @@ s32 CalcCritChanceStage(u8 battlerAtk, u8 battlerDef, u32 move, bool32 recordAbi + (holdEffectAtk == HOLD_EFFECT_SCOPE_LENS) + 2 * (holdEffectAtk == HOLD_EFFECT_LUCKY_PUNCH && gBattleMons[gBattlerAttacker].species == SPECIES_CHANSEY) + 2 * BENEFITS_FROM_LEEK(battlerAtk, holdEffectAtk) - + (abilityAtk == ABILITY_SUPER_LUCK) #if B_AFFECTION_MECHANICS == TRUE + + (abilityAtk == ABILITY_SUPER_LUCK) *= 2 (GetMonFriendshipScore(&gPlayerParty[gBattlerPartyIndexes[gBattlerAttacker]]) >= 5); + #else + + (abilityAtk == ABILITY_SUPER_LUCK); #endif if (critChance >= ARRAY_COUNT(sCriticalHitChance))