Moved item data constants into module ItemData

This commit is contained in:
Maruno17
2020-10-17 00:56:30 +01:00
parent 2b4f1e1aba
commit 7e627453da
10 changed files with 104 additions and 95 deletions

View File

@@ -7,7 +7,7 @@ class PokeBattle_AI
item, idxTarget = pbEnemyItemToUse(idxBattler)
return false if item==0
# Determine target of item (always the Pokémon choosing the action)
useType = pbGetItemData(item,ITEM_BATTLE_USE)
useType = pbGetItemData(item,ItemData::BATTLE_USE)
if useType && (useType==1 || useType==6) # Use on Pokémon
idxTarget = @battle.battlers[idxTarget].pokemonIndex # Party Pokémon
end