fix MOVE_TARGET_ALL_BATTLERS and other u8 vars
This commit is contained in:
parent
5509ceea04
commit
964e7efba9
4 changed files with 5 additions and 5 deletions
|
@ -386,6 +386,6 @@
|
|||
#define MOVE_TARGET_FOES_AND_ALLY 0x20
|
||||
#define MOVE_TARGET_OPPONENTS_FIELD 0x40
|
||||
#define MOVE_TARGET_ALLY 0x80
|
||||
#define MOVE_TARGET_ALL_BATTLERS 0x100
|
||||
#define MOVE_TARGET_ALL_BATTLERS (0x100 | MOVE_TARGET_USER)
|
||||
|
||||
#endif // GUARD_CONSTANTS_BATTLE_H
|
||||
|
|
|
@ -216,7 +216,7 @@ struct BattleMove
|
|||
u8 accuracy;
|
||||
u8 pp;
|
||||
u8 secondaryEffectChance;
|
||||
u8 target;
|
||||
u16 target;
|
||||
s8 priority;
|
||||
u32 flags;
|
||||
u8 split;
|
||||
|
|
|
@ -517,7 +517,7 @@ static s16 AI_CheckBadMove(u8 battlerAtk, u8 battlerDef, u16 move, s16 score)
|
|||
u8 atkPriority = GetMovePriority(battlerAtk, move);
|
||||
u16 moveEffect = gBattleMoves[move].effect;
|
||||
s32 moveType;
|
||||
u8 moveTarget = gBattleMoves[move].target;
|
||||
u16 moveTarget = gBattleMoves[move].target;
|
||||
u16 accuracy = AI_GetMoveAccuracy(battlerAtk, battlerDef, AI_DATA->atkAbility, AI_DATA->defAbility, AI_DATA->atkHoldEffect, AI_DATA->defHoldEffect, move);
|
||||
u8 effectiveness = AI_GetMoveEffectiveness(move, battlerAtk, battlerDef);
|
||||
bool32 isDoubleBattle = IsValidDoubleBattle(battlerAtk);
|
||||
|
@ -2514,7 +2514,7 @@ static s16 AI_DoubleBattle(u8 battlerAtk, u8 battlerDef, u16 move, s16 score)
|
|||
// move data
|
||||
u8 moveType = gBattleMoves[move].type;
|
||||
u16 effect = gBattleMoves[move].effect;
|
||||
u8 target = gBattleMoves[move].target;
|
||||
u16 target = gBattleMoves[move].target;
|
||||
// ally data
|
||||
u8 battlerAtkPartner = AI_DATA->battlerAtkPartner;
|
||||
u16 atkPartnerAbility = AI_DATA->atkPartnerAbility;
|
||||
|
|
|
@ -644,7 +644,7 @@ static void HandleInputChooseMove(void)
|
|||
// Show all available targets for multi-target moves
|
||||
if (B_SHOW_TARGETS)
|
||||
{
|
||||
if (moveTarget & MOVE_TARGET_ALL_BATTLERS)
|
||||
if ((moveTarget & MOVE_TARGET_ALL_BATTLERS) == MOVE_TARGET_ALL_BATTLERS)
|
||||
{
|
||||
u32 i = 0;
|
||||
for (i = 0; i < gBattlersCount; i++)
|
||||
|
|
Loading…
Reference in a new issue