Consider nature power in AI_CalcDamage

This commit is contained in:
Alex 2023-02-25 15:07:45 +01:00
parent 0669ac851f
commit 7ea82820ec
2 changed files with 5 additions and 1 deletions

View File

@ -744,6 +744,10 @@ s32 AI_CalcDamage(u16 move, u8 battlerAtk, u8 battlerDef, u8 *typeEffectiveness,
SetBattlerData(battlerDef);
gBattleStruct->dynamicMoveType = 0;
if (move == MOVE_NATURE_POWER)
move = GetNaturePowerMove();
SetTypeBeforeUsingMove(move, battlerAtk);
GET_MOVE_TYPE(move, moveType);

View File

@ -4847,7 +4847,7 @@ const struct BattleMove gBattleMoves[MOVES_COUNT_Z] =
[MOVE_NATURE_POWER] =
{
.effect = EFFECT_NATURE_POWER,
.power = 0,
.power = 1,
.type = TYPE_NORMAL,
.accuracy = 0,
.pp = 20,