mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 19:54:21 +01:00
b08c8f85fc
* Fixed Utility Umbrella holders not receiving regular damage when being hurt by what would've been weakened rain/sun attacks * Fixed reading move incorrectly * Tests: Sun, Rain, Utility Umbrella and Hydro Steam * [STASH] Skeli changes, needs to remake tests * Fixed tests * Removed redundant tests * Removed unused variable * Removed Primal Todo tests
48 lines
1.5 KiB
C
48 lines
1.5 KiB
C
#include "global.h"
|
|
#include "test_battle.h"
|
|
|
|
// Please add Sunlight interactions with move, item and ability effects on their respective files.
|
|
ASSUMPTIONS
|
|
{
|
|
ASSUME(gBattleMoves[MOVE_EMBER].type == TYPE_FIRE);
|
|
ASSUME(gBattleMoves[MOVE_WATER_GUN].type == TYPE_WATER);
|
|
}
|
|
|
|
SINGLE_BATTLE_TEST("Sunlight multiplies the power of Fire-type moves by 1.5x", s16 damage)
|
|
{
|
|
u32 setupMove;
|
|
PARAMETRIZE { setupMove = MOVE_CELEBRATE; }
|
|
PARAMETRIZE { setupMove = MOVE_SUNNY_DAY; }
|
|
GIVEN {
|
|
PLAYER(SPECIES_WOBBUFFET);
|
|
OPPONENT(SPECIES_WOBBUFFET);
|
|
} WHEN {
|
|
TURN { MOVE(player, setupMove); }
|
|
TURN { MOVE(player, MOVE_EMBER); }
|
|
} SCENE {
|
|
ANIMATION(ANIM_TYPE_MOVE, MOVE_EMBER, player);
|
|
HP_BAR(opponent, captureDamage: &results[i].damage);
|
|
} FINALLY {
|
|
EXPECT_MUL_EQ(results[0].damage, Q_4_12(1.5), results[1].damage);
|
|
}
|
|
}
|
|
|
|
SINGLE_BATTLE_TEST("Sunlight multiplies the power of Water-type moves by 0.5x", s16 damage)
|
|
{
|
|
u32 setupMove;
|
|
PARAMETRIZE { setupMove = MOVE_CELEBRATE; }
|
|
PARAMETRIZE { setupMove = MOVE_SUNNY_DAY; }
|
|
GIVEN {
|
|
PLAYER(SPECIES_WOBBUFFET);
|
|
OPPONENT(SPECIES_WOBBUFFET);
|
|
} WHEN {
|
|
TURN { MOVE(player, setupMove); }
|
|
TURN { MOVE(player, MOVE_WATER_GUN); }
|
|
} SCENE {
|
|
ANIMATION(ANIM_TYPE_MOVE, MOVE_WATER_GUN, player);
|
|
HP_BAR(opponent, captureDamage: &results[i].damage);
|
|
} FINALLY {
|
|
EXPECT_MUL_EQ(results[0].damage, Q_4_12(0.5), results[1].damage);
|
|
}
|
|
}
|