mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-01-18 17:34:20 +01:00
Stamina, Liquid Voice, Water Compaction
This commit is contained in:
parent
8ea7fcc348
commit
83b251a69c
@ -5055,6 +5055,11 @@ void SetTypeBeforeUsingMove(u16 move, u8 battlerAtk)
|
||||
gBattleStruct->dynamicMoveType = 0x80 | TYPE_NORMAL;
|
||||
gBattleStruct->ateBoost[battlerAtk] = 1;
|
||||
}
|
||||
else if (gBattleMoves[move].flags & FLAG_SOUND
|
||||
&& attackerAbility == ABILITY_LIQUID_VOICE)
|
||||
{
|
||||
gBattleStruct->dynamicMoveType = 0x80 | TYPE_WATER;
|
||||
}
|
||||
|
||||
// Check if a gem should activate.
|
||||
GET_MOVE_TYPE(move, moveType);
|
||||
|
@ -3291,6 +3291,31 @@ u8 AbilityBattleEffects(u8 caseID, u8 battler, u8 ability, u8 special, u16 moveA
|
||||
effect++;
|
||||
}
|
||||
break;
|
||||
case ABILITY_WATER_COMPACTION:
|
||||
if (!(gMoveResultFlags & MOVE_RESULT_NO_EFFECT)
|
||||
&& TARGET_TURN_DAMAGED
|
||||
&& IsBattlerAlive(battler)
|
||||
&& moveType == TYPE_WATER
|
||||
&& gBattleMons[battler].statStages[STAT_DEF] != 12)
|
||||
{
|
||||
SET_STATCHANGER(STAT_DEF, 2, FALSE);
|
||||
BattleScriptPushCursor();
|
||||
gBattlescriptCurrInstr = BattleScript_TargetAbilityStatRaise;
|
||||
effect++;
|
||||
}
|
||||
break;
|
||||
case ABILITY_STAMINA:
|
||||
if (!(gMoveResultFlags & MOVE_RESULT_NO_EFFECT)
|
||||
&& TARGET_TURN_DAMAGED
|
||||
&& IsBattlerAlive(battler)
|
||||
&& gBattleMons[battler].statStages[STAT_DEF] != 12)
|
||||
{
|
||||
SET_STATCHANGER(STAT_DEF, 1, FALSE);
|
||||
BattleScriptPushCursor();
|
||||
gBattlescriptCurrInstr = BattleScript_TargetAbilityStatRaise;
|
||||
effect++;
|
||||
}
|
||||
break;
|
||||
case ABILITY_BERSERK:
|
||||
if (!(gMoveResultFlags & MOVE_RESULT_NO_EFFECT)
|
||||
&& TARGET_TURN_DAMAGED
|
||||
|
Loading…
x
Reference in New Issue
Block a user