Added conversion of berry plant data, removed all uses of ID numbers for abilities and berry plants, fixed mulch not being consumed, removed use of ID numbers in map of moves to animation IDs

This commit is contained in:
Maruno17
2021-06-19 18:48:33 +01:00
parent 6e188666a4
commit 49655165e1
9 changed files with 134 additions and 48 deletions

View File

@@ -456,7 +456,10 @@ class Pokemon
# @return [GameData::Nature, nil] a Nature object corresponding to this Pokémon's nature
def nature
@nature = GameData::Nature.get(@personalID % GameData::Nature.count).id if !@nature
if !@nature
idx = @personalID % GameData::Nature.count
@nature = GameData::Nature.get(GameData::Nature.keys[idx]).id
end
return GameData::Nature.try_get(@nature)
end