summaryrefslogtreecommitdiff
path: root/src/dungeon_ai_items.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/dungeon_ai_items.c')
-rw-r--r--src/dungeon_ai_items.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/dungeon_ai_items.c b/src/dungeon_ai_items.c
index 2b1bb71..5e60708 100644
--- a/src/dungeon_ai_items.c
+++ b/src/dungeon_ai_items.c
@@ -40,7 +40,7 @@ extern void sub_8077274(struct DungeonEntity *, struct DungeonEntity *);
extern s32 gNumPotentialTargets;
extern u32 gPotentialTargetWeights[NUM_DIRECTIONS];
-extern u32 gPotentialTargetDirections[NUM_DIRECTIONS];
+extern u32 gPotentialItemTargetDirections[NUM_DIRECTIONS];
extern bool8 gTargetAhead[NUM_DIRECTIONS];
extern struct TeamInventory *gTeamInventory_203B460;
@@ -101,7 +101,7 @@ void DecideUseItem(struct DungeonEntity *pokemon)
pokemonData->action.actionUseIndex = selectedToolboxIndex;
pokemonData->action.lastItemThrowPosition.x = pokemon->posWorld.x;
pokemonData->action.lastItemThrowPosition.y = pokemon->posWorld.y;
- pokemonData->action.facingDir = gPotentialTargetDirections[targetIndex] & DIRECTION_MASK;
+ pokemonData->action.facingDir = gPotentialItemTargetDirections[targetIndex] & DIRECTION_MASK;
break;
}
}
@@ -261,7 +261,7 @@ void DecideUseItem(struct DungeonEntity *pokemon)
pokemonData->action.actionUseIndex = selectedToolboxIndex;
pokemonData->action.lastItemThrowPosition.x = pokemon->posWorld.x;
pokemonData->action.lastItemThrowPosition.y = pokemon->posWorld.y;
- pokemonData->action.facingDir = gPotentialTargetDirections[targetIndex] & DIRECTION_MASK;
+ pokemonData->action.facingDir = gPotentialItemTargetDirections[targetIndex] & DIRECTION_MASK;
return;
}
}
@@ -421,7 +421,7 @@ void TargetThrownItem(struct DungeonEntity *pokemon, struct DungeonEntity *targe
u32 itemWeight;
u32 *targetWeight;
gTargetAhead[targetDirection] = TRUE;
- gPotentialTargetDirections[gNumPotentialTargets] = targetDirection;
+ gPotentialItemTargetDirections[gNumPotentialTargets] = targetDirection;
targetWeight = &gPotentialTargetWeights[gNumPotentialTargets];
itemWeight = !ignoreRollChance ? EvaluateItem(targetPokemon, item, targetingFlags) : 100;
*targetWeight = itemWeight;