mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2026-01-23 06:46:00 +00:00
Consolidated code for the player interacting in the overworld, fixed bad splash screen animations, added ShowQuantity property to items.txt, fixed Quick Draw and Aroma Veil, fixed text alignment in long list of regional Dexes in Pokédex, added better error message in load screen if player's charset is missing
This commit is contained in:
@@ -199,12 +199,19 @@ class Battle
|
||||
entry[5] = pri
|
||||
choice[4] = pri
|
||||
end
|
||||
# Recalculate sub-priority change caused by ability (but not by item)
|
||||
if entry[0].abilityActive?
|
||||
subPri = Battle::AbilityEffects.triggerPriorityBracketChange(entry[0].ability, entry[0], self)
|
||||
needRearranging = true if subPri != entry[2]
|
||||
entry[2] = subPri
|
||||
end
|
||||
# NOTE: If the battler's ability at the start of this round was one with
|
||||
# a PriorityBracketChange handler (i.e. Quick Draw), but it Mega
|
||||
# Evolved and now doesn't have that ability, that old ability's
|
||||
# priority bracket modifier will still apply. Similarly, if its
|
||||
# old ability did not have a PriorityBracketChange handler but it
|
||||
# Mega Evolved and now does have it, it will not apply this round.
|
||||
# This is because the message saying that it had an effect appears
|
||||
# before Mega Evolution happens, and recalculating it now would
|
||||
# make that message inaccurate because Quick Draw only has a
|
||||
# chance of triggering. However, since Quick Draw is exclusive to
|
||||
# a species that doesn't Mega Evolve, these circumstances should
|
||||
# never arise and no one will notice that the priority bracket
|
||||
# change isn't recalculated when technically it should be.
|
||||
end
|
||||
end
|
||||
# Calculate each battler's overall sub-priority, and whether its ability or
|
||||
|
||||
@@ -532,15 +532,15 @@ class Battle::Battler
|
||||
allAllies.each do |b|
|
||||
next if !b.hasActiveAbility?(:AROMAVEIL)
|
||||
if showMessages
|
||||
@battle.pbShowAbilitySplash(self)
|
||||
@battle.pbShowAbilitySplash(b)
|
||||
if Battle::Scene::USE_ABILITY_SPLASH
|
||||
@battle.pbDisplay(_INTL("{1} is unaffected!", pbThis))
|
||||
else
|
||||
@battle.pbDisplay(_INTL("{1}'s {2} prevents romance!", b.pbThis, b.abilityName))
|
||||
end
|
||||
@battle.pbHideAbilitySplash(self)
|
||||
@battle.pbHideAbilitySplash(b)
|
||||
end
|
||||
return true
|
||||
return false
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -143,14 +143,14 @@ class Battle::Move
|
||||
target.allAllies.each do |b|
|
||||
next if !b.hasActiveAbility?(:AROMAVEIL)
|
||||
if showMessage
|
||||
@battle.pbShowAbilitySplash(target)
|
||||
@battle.pbShowAbilitySplash(b)
|
||||
if Battle::Scene::USE_ABILITY_SPLASH
|
||||
@battle.pbDisplay(_INTL("{1} is unaffected!", target.pbThis))
|
||||
else
|
||||
@battle.pbDisplay(_INTL("{1} is unaffected because of {2}'s {3}!",
|
||||
target.pbThis, b.pbThis(true), b.abilityName))
|
||||
end
|
||||
@battle.pbHideAbilitySplash(target)
|
||||
@battle.pbHideAbilitySplash(b)
|
||||
end
|
||||
return true
|
||||
end
|
||||
|
||||
@@ -639,7 +639,6 @@ class Battle::Move::AttractTarget < Battle::Move
|
||||
def pbFailsAgainstTarget?(user, target, show_message)
|
||||
return false if damagingMove?
|
||||
return true if !target.pbCanAttract?(user, show_message)
|
||||
return true if pbMoveFailedAromaVeil?(user, target, show_message)
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
@@ -289,10 +289,10 @@ class Battle::Move::StartNegateHeldItems < Battle::Move
|
||||
end
|
||||
|
||||
#===============================================================================
|
||||
# The user consumes its held berry and gains its effect. Also, increases the
|
||||
# user's Defense by 2 stages. The berry can be consumed even if Unnerve/Magic
|
||||
# Room apply. Fails if the user is not holding a berry. This move cannot be
|
||||
# chosen to be used if the user is not holding a berry. (Stuff Cheeks)
|
||||
# The user consumes its held berry increases its Defense by 2 stages. It also
|
||||
# gains the berry's effect if it has one. The berry can be consumed even if
|
||||
# Unnerve/Magic Room apply. Fails if the user is not holding a berry. This move
|
||||
# cannot be chosen to be used if the user is not holding a berry. (Stuff Cheeks)
|
||||
#===============================================================================
|
||||
class Battle::Move::UserConsumeBerryRaiseDefense2 < Battle::Move::StatUpMove
|
||||
def initialize(battle, move)
|
||||
@@ -319,7 +319,6 @@ class Battle::Move::UserConsumeBerryRaiseDefense2 < Battle::Move::StatUpMove
|
||||
@battle.pbDisplay(_INTL("But it failed!"))
|
||||
return true
|
||||
end
|
||||
# TODO: Should this return super? It can consume the berry at this point.
|
||||
return super
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user