hidden power error fix

This commit is contained in:
infinitefusion
2022-05-15 09:25:04 -04:00
parent 66e7d03fbd
commit bbf4bc6e9b
14 changed files with 9 additions and 4 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -243,13 +243,13 @@ end
#===============================================================================
class PokeBattle_Move_090 < PokeBattle_Move
def pbBaseType(user)
hp = pbHiddenPower(user,user.hiddenPowerType)
hp = pbHiddenPower(user,user.pokemon.hiddenPowerType)
return hp[0]
end
def pbBaseDamage(baseDmg,user,target)
return super if Settings::MECHANICS_GENERATION >= 6
hp = pbHiddenPower(user,user.hiddenPowerType)
hp = pbHiddenPower(user,user.pokemon.hiddenPowerType)
return hp[1]
end
end

View File

@@ -137,7 +137,7 @@ def pbAddForeignPokemon(pkmn, level = 1, owner_name = nil, nickname = nil, owner
end
def pbGenerateEgg(pkmn, text = "")
return false if !pkmn || $Trainer.party_full?
return false if !pkmn #|| $Trainer.party_full?
pkmn = Pokemon.new(pkmn, Settings::EGG_LEVEL) if !pkmn.is_a?(Pokemon)
# Set egg's details
pkmn.name = _INTL("Egg")
@@ -145,7 +145,12 @@ def pbGenerateEgg(pkmn, text = "")
pkmn.obtain_text = text
pkmn.calc_stats
# Add egg to party
$Trainer.party[$Trainer.party.length] = pkmn
if $Trainer.party.length<6
$Trainer.party[$Trainer.party.length] = pkmn
else
$PokemonStorage.pbStoreCaught(pkmn)
Kernel.pbMessage(_INTL("The egg was transfered to the PC."))
end
return true
end
alias pbAddEgg pbGenerateEgg

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.