summaryrefslogtreecommitdiff
path: root/src/battle/calculate_base_damage.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/battle/calculate_base_damage.c')
-rw-r--r--src/battle/calculate_base_damage.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/battle/calculate_base_damage.c b/src/battle/calculate_base_damage.c
index 8dc4108d9..d983e47a4 100644
--- a/src/battle/calculate_base_damage.c
+++ b/src/battle/calculate_base_damage.c
@@ -170,7 +170,7 @@ s32 CalculateBaseDamage(struct BattlePokemon *attacker, struct BattlePokemon *de
if (attackerHoldEffect == gHoldEffectToType[i][0]
&& type == gHoldEffectToType[i][1])
{
- if (type < TYPE_MYSTERY)
+ if (TYPE_IS_PHYSICAL(type))
attack = (attack * (attackerHoldEffectParam + 100)) / 100;
else
spAttack = (spAttack * (attackerHoldEffectParam + 100)) / 100;
@@ -221,7 +221,7 @@ s32 CalculateBaseDamage(struct BattlePokemon *attacker, struct BattlePokemon *de
if (gBattleMoves[gCurrentMove].effect == EFFECT_EXPLOSION)
defense /= 2;
- if (type < TYPE_MYSTERY) // is physical
+ if (TYPE_IS_PHYSICAL(type)) // type < TYPE_MYSTERY
{
if (gCritMultiplier == 2)
{
@@ -271,7 +271,7 @@ s32 CalculateBaseDamage(struct BattlePokemon *attacker, struct BattlePokemon *de
if (type == TYPE_MYSTERY)
damage = 0; // is ??? type. does 0 damage.
- if (type > TYPE_MYSTERY) // is special?
+ if (TYPE_IS_SPECIAL(type)) // type > TYPE_MYSTERY
{
if (gCritMultiplier == 2)
{