mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-27 04:04:17 +01:00
28c6a1af49
Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>
81 lines
2.6 KiB
C
81 lines
2.6 KiB
C
#include "global.h"
|
|
#include "test/battle.h"
|
|
|
|
ASSUMPTIONS
|
|
{
|
|
ASSUME(gBattleMoves[MOVE_WEATHER_BALL].effect == EFFECT_WEATHER_BALL);
|
|
}
|
|
|
|
SINGLE_BATTLE_TEST("Weather Ball doubles its power and turns to a Fire-type move in Sunlight", s16 damage)
|
|
{
|
|
u16 move;
|
|
PARAMETRIZE{ move = MOVE_CELEBRATE; }
|
|
PARAMETRIZE{ move = MOVE_SUNNY_DAY; }
|
|
GIVEN {
|
|
PLAYER(SPECIES_WOBBUFFET);
|
|
OPPONENT(SPECIES_MEGANIUM);
|
|
} WHEN {
|
|
TURN { MOVE(player, move); }
|
|
TURN { MOVE(player, MOVE_WEATHER_BALL); }
|
|
} SCENE {
|
|
HP_BAR(opponent, captureDamage: &results[i].damage);
|
|
} FINALLY {
|
|
EXPECT_MUL_EQ(results[0].damage, Q_4_12(6.0), results[1].damage); // double base power + type effectiveness + sun 50% boost
|
|
}
|
|
}
|
|
|
|
SINGLE_BATTLE_TEST("Weather Ball doubles its power and turns to a Water-type move in Rain", s16 damage)
|
|
{
|
|
u16 move;
|
|
PARAMETRIZE{ move = MOVE_CELEBRATE; }
|
|
PARAMETRIZE{ move = MOVE_RAIN_DANCE; }
|
|
GIVEN {
|
|
PLAYER(SPECIES_WOBBUFFET);
|
|
OPPONENT(SPECIES_ARCANINE);
|
|
} WHEN {
|
|
TURN { MOVE(player, move); }
|
|
TURN { MOVE(player, MOVE_WEATHER_BALL); }
|
|
} SCENE {
|
|
HP_BAR(opponent, captureDamage: &results[i].damage);
|
|
} FINALLY {
|
|
EXPECT_MUL_EQ(results[0].damage, Q_4_12(6.0), results[1].damage); // double base power + type effectiveness + rain 50% boost
|
|
}
|
|
}
|
|
|
|
SINGLE_BATTLE_TEST("Weather Ball doubles its power and turns to a Rock-type move in a Sandstorm", s16 damage)
|
|
{
|
|
u16 move;
|
|
PARAMETRIZE{ move = MOVE_CELEBRATE; }
|
|
PARAMETRIZE{ move = MOVE_SANDSTORM; }
|
|
GIVEN {
|
|
PLAYER(SPECIES_WOBBUFFET);
|
|
OPPONENT(SPECIES_MAGMAR) { Item(ITEM_SAFETY_GOGGLES); };
|
|
} WHEN {
|
|
TURN { MOVE(player, move); }
|
|
TURN { MOVE(player, MOVE_WEATHER_BALL); }
|
|
} SCENE {
|
|
HP_BAR(opponent, captureDamage: &results[i].damage);
|
|
} FINALLY {
|
|
EXPECT_MUL_EQ(results[0].damage, Q_4_12(4.0), results[1].damage); // double base power + type effectiveness.
|
|
}
|
|
}
|
|
|
|
SINGLE_BATTLE_TEST("Weather Ball doubles its power and turns to an Ice-type move in Hail and Snow", s16 damage)
|
|
{
|
|
u16 move;
|
|
PARAMETRIZE{ move = MOVE_CELEBRATE; }
|
|
PARAMETRIZE{ move = MOVE_HAIL; }
|
|
PARAMETRIZE{ move = MOVE_SNOWSCAPE; }
|
|
GIVEN {
|
|
PLAYER(SPECIES_WOBBUFFET);
|
|
OPPONENT(SPECIES_DRAGONAIR) { Item(ITEM_SAFETY_GOGGLES); };
|
|
} WHEN {
|
|
TURN { MOVE(player, move); }
|
|
TURN { MOVE(player, MOVE_WEATHER_BALL); }
|
|
} SCENE {
|
|
HP_BAR(opponent, captureDamage: &results[i].damage);
|
|
} FINALLY {
|
|
EXPECT_MUL_EQ(results[0].damage, Q_4_12(4.0), results[1].damage); // double base power + type effectiveness.
|
|
}
|
|
}
|