mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-11 23:24:59 +00:00
Fixed Magic Guard not being checked for damage from Shadow Sky weather/Spiky Shield/Dry Skin/Solar Power, fixed As One not having Unnerve's effect, fixed Gulp Missile paralysing the wrong Pokémon, added message for obtaining multiple machine items at once
This commit is contained in:
@@ -13,7 +13,7 @@ class Battle::Battler
|
||||
@fainted = true
|
||||
# Check for end of Neutralizing Gas/Unnerve
|
||||
pbAbilitiesOnNeutralizingGasEnding if hasActiveAbility?(:NEUTRALIZINGGAS, true)
|
||||
pbItemsOnUnnerveEnding if hasActiveAbility?(:UNNERVE, true)
|
||||
pbItemsOnUnnerveEnding if hasActiveAbility?([:UNNERVE, :ASONECHILLINGNEIGH, :ASONEGRIMNEIGH], true)
|
||||
# Check for end of primordial weather
|
||||
@battle.pbEndPrimordialWeather
|
||||
end
|
||||
@@ -29,7 +29,7 @@ class Battle::Battler
|
||||
Battle::AbilityEffects.triggerOnBattlerFainting(b.ability, b, self, @battle)
|
||||
end
|
||||
pbAbilitiesOnNeutralizingGasEnding if hasActiveAbility?(:NEUTRALIZINGGAS, true)
|
||||
pbItemsOnUnnerveEnding if hasActiveAbility?(:UNNERVE, true)
|
||||
pbItemsOnUnnerveEnding if hasActiveAbility?([:UNNERVE, :ASONECHILLINGNEIGH, :ASONEGRIMNEIGH], true)
|
||||
end
|
||||
|
||||
# Used for Emergency Exit/Wimp Out. Returns whether self has switched out.
|
||||
@@ -162,7 +162,8 @@ class Battle::Battler
|
||||
def pbOnLosingAbility(oldAbil, suppressed = false)
|
||||
if oldAbil == :NEUTRALIZINGGAS && (suppressed || !@effects[PBEffects::GastroAcid])
|
||||
pbAbilitiesOnNeutralizingGasEnding
|
||||
elsif oldAbil == :UNNERVE && (suppressed || !@effects[PBEffects::GastroAcid])
|
||||
elsif [:UNNERVE, :ASONECHILLINGNEIGH, :ASONEGRIMNEIGH].include?(oldAbil) &&
|
||||
(suppressed || !@effects[PBEffects::GastroAcid])
|
||||
pbItemsOnUnnerveEnding
|
||||
elsif oldAbil == :ILLUSION && @effects[PBEffects::Illusion]
|
||||
@effects[PBEffects::Illusion] = nil
|
||||
@@ -200,7 +201,7 @@ class Battle::Battler
|
||||
# Held item consuming/removing
|
||||
#=============================================================================
|
||||
def canConsumeBerry?
|
||||
return false if @battle.pbCheckOpposingAbility(:UNNERVE, @index)
|
||||
return false if @battle.pbCheckOpposingAbility([:UNNERVE, :ASONECHILLINGNEIGH, :ASONEGRIMNEIGH], @index)
|
||||
return true
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user