mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-06 06:01:46 +00:00
Merge branch 'dev' into ai
This commit is contained in:
@@ -33,15 +33,6 @@ module Battle::CatchAndStoreMixin
|
|||||||
next if party_index < 0 # Cancelled
|
next if party_index < 0 # Cancelled
|
||||||
party_size = pbPlayer.party.length
|
party_size = pbPlayer.party.length
|
||||||
# Send chosen Pokémon to storage
|
# Send chosen Pokémon to storage
|
||||||
# NOTE: This doesn't work properly if you catch multiple Pokémon in
|
|
||||||
# the same battle, because the code below doesn't alter the
|
|
||||||
# contents of pbParty(0), only pbPlayer.party. This means that
|
|
||||||
# viewing the party in battle after replacing a party Pokémon
|
|
||||||
# with a caught one (which is possible if you've caught a second
|
|
||||||
# Pokémon) will not show the first caught Pokémon in the party
|
|
||||||
# but will still show the boxed Pokémon in the party. Correcting
|
|
||||||
# this would take a surprising amount of code, and it's very
|
|
||||||
# unlikely to be needed anyway, so I'm ignoring it for now.
|
|
||||||
send_pkmn = pbPlayer.party[party_index]
|
send_pkmn = pbPlayer.party[party_index]
|
||||||
stored_box = @peer.pbStorePokemon(pbPlayer, send_pkmn)
|
stored_box = @peer.pbStorePokemon(pbPlayer, send_pkmn)
|
||||||
pbPlayer.party.delete_at(party_index)
|
pbPlayer.party.delete_at(party_index)
|
||||||
|
|||||||
@@ -1318,13 +1318,13 @@ Battle::ItemEffects::OnBeingHit.add(:JABOCABERRY,
|
|||||||
next if !user.takesIndirectDamage?
|
next if !user.takesIndirectDamage?
|
||||||
amt = user.totalhp / 8
|
amt = user.totalhp / 8
|
||||||
ripening = false
|
ripening = false
|
||||||
if battler.hasActiveAbility?(:RIPEN)
|
if target.hasActiveAbility?(:RIPEN)
|
||||||
battle.pbShowAbilitySplash(battler)
|
battle.pbShowAbilitySplash(target)
|
||||||
amt *= 2
|
amt *= 2
|
||||||
ripening = true
|
ripening = true
|
||||||
end
|
end
|
||||||
battle.pbCommonAnimation("EatBerry", target)
|
battle.pbCommonAnimation("EatBerry", target)
|
||||||
battle.pbHideAbilitySplash(battler) if ripening
|
battle.pbHideAbilitySplash(target) if ripening
|
||||||
battle.scene.pbDamageAnimation(user)
|
battle.scene.pbDamageAnimation(user)
|
||||||
user.pbReduceHP(amt, false)
|
user.pbReduceHP(amt, false)
|
||||||
battle.pbDisplay(_INTL("{1} consumed its {2} and hurt {3}!", target.pbThis,
|
battle.pbDisplay(_INTL("{1} consumed its {2} and hurt {3}!", target.pbThis,
|
||||||
@@ -1388,13 +1388,13 @@ Battle::ItemEffects::OnBeingHit.add(:ROWAPBERRY,
|
|||||||
next if !user.takesIndirectDamage?
|
next if !user.takesIndirectDamage?
|
||||||
amt = user.totalhp / 8
|
amt = user.totalhp / 8
|
||||||
ripening = false
|
ripening = false
|
||||||
if battler.hasActiveAbility?(:RIPEN)
|
if target.hasActiveAbility?(:RIPEN)
|
||||||
battle.pbShowAbilitySplash(battler)
|
battle.pbShowAbilitySplash(target)
|
||||||
amt *= 2
|
amt *= 2
|
||||||
ripening = true
|
ripening = true
|
||||||
end
|
end
|
||||||
battle.pbCommonAnimation("EatBerry", target)
|
battle.pbCommonAnimation("EatBerry", target)
|
||||||
battle.pbHideAbilitySplash(battler) if ripening
|
battle.pbHideAbilitySplash(target) if ripening
|
||||||
battle.scene.pbDamageAnimation(user)
|
battle.scene.pbDamageAnimation(user)
|
||||||
user.pbReduceHP(amt, false)
|
user.pbReduceHP(amt, false)
|
||||||
battle.pbDisplay(_INTL("{1} consumed its {2} and hurt {3}!", target.pbThis,
|
battle.pbDisplay(_INTL("{1} consumed its {2} and hurt {3}!", target.pbThis,
|
||||||
|
|||||||
Reference in New Issue
Block a user