small fixes

This commit is contained in:
ghoulslash 2022-12-06 11:12:20 -05:00
parent 5a26a69ccd
commit c327655ef5
2 changed files with 7 additions and 4 deletions

View File

@ -2832,7 +2832,7 @@ void SetMoveEffect(bool32 primary, u32 certain)
&& (gBattleScripting.moveEffect <= MOVE_EFFECT_TRI_ATTACK || gBattleScripting.moveEffect >= MOVE_EFFECT_SMACK_DOWN)) // Exclude stat lowering effects
{
if (battlerAbility == ABILITY_SHIELD_DUST)
RecordAbilityBattle(gEffectBattler, battlerAbility)
RecordAbilityBattle(gEffectBattler, battlerAbility);
else
RecordItemEffectBattle(gEffectBattler, HOLD_EFFECT_COVERT_CLOAK);
INCREMENT_RESET_RETURN
@ -8720,7 +8720,8 @@ static void Cmd_various(void)
gBattlerAbility = BATTLE_PARTNER(gActiveBattler);
i = GetBattlerAbility(gBattlerAbility);
if (IsBattlerAlive(gBattlerAbility)
&& (i == ABILITY_RECEIVER || i == ABILITY_POWER_OF_ALCHEMY))
&& (i == ABILITY_RECEIVER || i == ABILITY_POWER_OF_ALCHEMY)
&& GetBattlerHoldEffect(gActiveBattler, TRUE) != HOLD_EFFECT_ABILITY_SHIELD)
{
switch (gBattleMons[gActiveBattler].ability)
{ // Can't copy these abilities.

View File

@ -5379,7 +5379,8 @@ u8 AbilityBattleEffects(u8 caseID, u8 battler, u16 ability, u8 special, u16 move
case ABILITY_STANCE_CHANGE:
break;
default:
if (GetBattlerHoldEffect(gBattlerAttacker, TRUE) == HOLD_EFFECT_ABILITY_SHIELD) {
if (GetBattlerHoldEffect(gBattlerAttacker, TRUE) == HOLD_EFFECT_ABILITY_SHIELD)
{
RecordItemEffectBattle(gBattlerAttacker, HOLD_EFFECT_ABILITY_SHIELD);
break;
}
@ -5415,7 +5416,8 @@ u8 AbilityBattleEffects(u8 caseID, u8 battler, u16 ability, u8 special, u16 move
case ABILITY_ZEN_MODE:
break;
default:
if (GetBattlerHoldEffect(gBattlerAttacker, TRUE) == HOLD_EFFECT_ABILITY_SHIELD) {
if (GetBattlerHoldEffect(gBattlerAttacker, TRUE) == HOLD_EFFECT_ABILITY_SHIELD)
{
RecordItemEffectBattle(gBattlerAttacker, HOLD_EFFECT_ABILITY_SHIELD);
break;
}