Added class Data::Ability and made all code use symbols for abilities instead of numbers. Also added class Data::Item but it's unused.

This commit is contained in:
Maruno17
2020-11-01 20:10:28 +00:00
parent c4e69d0a2e
commit 213347b938
34 changed files with 590 additions and 345 deletions

View File

@@ -168,7 +168,7 @@ class PokeBattle_Battle
@battlers[0].effects[PBEffects::Outrage]==0
idxPartyForName = idxPartyNew
enemyParty = pbParty(idxBattler)
if isConst?(enemyParty[idxPartyNew].ability,PBAbilities,:ILLUSION)
if enemyParty[idxPartyNew].ability == :ILLUSION
idxPartyForName = pbLastInTeam(idxBattler)
end
if pbDisplayConfirm(_INTL("{1} is about to send in {2}. Will you switch your Pokémon?",
@@ -254,7 +254,7 @@ class PokeBattle_Battle
def pbMessagesOnReplace(idxBattler,idxParty)
party = pbParty(idxBattler)
newPkmnName = party[idxParty].name
if isConst?(party[idxParty].ability,PBAbilities,:ILLUSION)
if party[idxParty].ability == :ILLUSION
newPkmnName = party[pbLastInTeam(idxBattler)].name
end
if pbOwnedByPlayer?(idxBattler)