summaryrefslogtreecommitdiff
path: root/src/battle_ai_switch_items.c
diff options
context:
space:
mode:
authorGriffinR <griffin.g.richards@gmail.com>2020-01-08 01:15:36 -0500
committerGitHub <noreply@github.com>2020-01-08 01:15:36 -0500
commite5df61e362beaaab9ae4344f4f160397df9c54cc (patch)
tree8bb86e5e523406b21daa08aff9bce080184fe31e /src/battle_ai_switch_items.c
parent017fa294b5c88ddd7513cb4976b5c29cad0b94a5 (diff)
parent8b1595ebc36a623240fa8dd509864f5400eed1f9 (diff)
Merge branch 'master' into doc-dome
Diffstat (limited to 'src/battle_ai_switch_items.c')
-rw-r--r--src/battle_ai_switch_items.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/battle_ai_switch_items.c b/src/battle_ai_switch_items.c
index 6ef359150..32f9620b7 100644
--- a/src/battle_ai_switch_items.c
+++ b/src/battle_ai_switch_items.c
@@ -787,9 +787,9 @@ static u8 GetAI_ItemType(u8 itemId, const u8 *itemEffect) // NOTE: should take u
return AI_ITEM_HEAL_HP;
else if (itemEffect[3] & ITEM3_STATUS_ALL)
return AI_ITEM_CURE_CONDITION;
- else if (itemEffect[0] & (ITEM0_HIGH_CRIT | ITEM0_X_ATTACK) || itemEffect[1] != 0 || itemEffect[2] != 0)
+ else if (itemEffect[0] & (ITEM0_DIRE_HIT | ITEM0_X_ATTACK) || itemEffect[1] != 0 || itemEffect[2] != 0)
return AI_ITEM_X_STAT;
- else if (itemEffect[3] & ITEM3_MIST)
+ else if (itemEffect[3] & ITEM3_GUARD_SPEC)
return AI_ITEM_GUARD_SPECS;
else
return AI_ITEM_NOT_RECOGNIZABLE;
@@ -907,7 +907,7 @@ static bool8 ShouldUseItem(void)
*(gBattleStruct->AI_itemFlags + gActiveBattler / 2) |= 0x8;
if (itemEffects[2] & ITEM2_X_ACCURACY)
*(gBattleStruct->AI_itemFlags + gActiveBattler / 2) |= 0x20;
- if (itemEffects[0] & ITEM0_HIGH_CRIT)
+ if (itemEffects[0] & ITEM0_DIRE_HIT)
*(gBattleStruct->AI_itemFlags + gActiveBattler / 2) |= 0x80;
shouldUse = TRUE;
break;