Fixes z-move priority (#3690)

* Fixes z-move priority

* consider prankster affected z moves

* consider only damaging moves
This commit is contained in:
Alex 2023-12-11 19:20:14 +01:00 committed by GitHub
parent 403843cecf
commit 22280b4778
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4691,6 +4691,9 @@ s8 GetMovePriority(u32 battler, u16 move)
s8 priority;
u16 ability = GetBattlerAbility(battler);
if (gBattleStruct->zmove.toBeUsed[battler] && gBattleMoves[move].power != 0)
move = gBattleStruct->zmove.toBeUsed[battler];
priority = gBattleMoves[move].priority;
if (ability == ABILITY_GALE_WINGS
#if B_GALE_WINGS >= GEN_7