forked from rh-hideout/pokeemerald-expansion
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add check for Magic Guard to avoid taking recoil damage (rh-hideout#4578
) * Add check for Magic Guard to avoid taking recoil damage * add test to verify a mon with magic guard does not take recoil damage followed format from "Steel Beam hp loss is prevented by Magic Guard" test * update format of tests with magic guard and some form of recoil damage
- Loading branch information
Showing
4 changed files
with
22 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#include "global.h" | ||
#include "test/battle.h" | ||
|
||
SINGLE_BATTLE_TEST("Magic Guard prevents recoil damage to the user") | ||
{ | ||
GIVEN { | ||
ASSUME(gMovesInfo[MOVE_DOUBLE_EDGE].recoil == 33); | ||
PLAYER(SPECIES_CLEFABLE) { Ability(ABILITY_MAGIC_GUARD); } | ||
OPPONENT(SPECIES_WOBBUFFET); | ||
} WHEN { | ||
TURN { MOVE(player, MOVE_DOUBLE_EDGE); } | ||
} SCENE { | ||
ANIMATION(ANIM_TYPE_MOVE, MOVE_DOUBLE_EDGE, player); | ||
HP_BAR(opponent); | ||
NOT HP_BAR(player); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters