mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-10 06:34:59 +00:00
corrupted data
This commit is contained in:
@@ -42,6 +42,7 @@ class PokeBattle_Battler
|
||||
attr_accessor :tookPhysicalHit
|
||||
attr_accessor :damageState
|
||||
attr_accessor :initialHP # Set at the start of each move's usage
|
||||
attr_accessor :hasTempSpeciesChange
|
||||
|
||||
#=============================================================================
|
||||
# Complex accessors
|
||||
|
||||
@@ -614,8 +614,7 @@ class PokeBattle_Battler
|
||||
end
|
||||
playChangeFormAnimation(animation)
|
||||
end
|
||||
|
||||
|
||||
|
||||
|
||||
# def changeUnfusedSpecies(pokemon, newSpecies, animation = "UltraBurst2")
|
||||
#
|
||||
|
||||
@@ -1504,6 +1504,48 @@ BattleHandlers::TargetAbilityOnHit.add(:JUSTIFIED,
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::TargetAbilityOnHit.add(:CORRUPTION,
|
||||
proc { |ability,user,target,move,battle|
|
||||
next if user.fainted?
|
||||
next if user.ability == :CORRUPTION
|
||||
oldAbil = nil
|
||||
|
||||
#next if user.unstoppableAbility? || user.ability == ability
|
||||
if move.specialMove?
|
||||
user.pokemon.tempSpeciesChange_originalSpecies = user.pokemon.species if !user.pokemon.tempSpeciesChange_originalSpecies
|
||||
user.pokemon.species = user.pokemon.tempSpeciesChange_originalSpecies
|
||||
battle.pbShowAbilitySplash(target) if user.opposes?(target)
|
||||
body_species_number = GameData::Species.get(user.pokemon.species).get_body_species
|
||||
body_species = GameData::Species.get(body_species_number).id
|
||||
oldAbil = user.ability
|
||||
user.ability = ability
|
||||
|
||||
user.changeSpecies(user.pokemon, body_species, :MISSINGNO, "Paralysis")
|
||||
user.pbUpdate(true)
|
||||
battle.scene.pbChangePokemon(user,user.pokemon)
|
||||
battle.scene.pbRefreshOne(user.index)
|
||||
elsif move.physicalMove?
|
||||
user.pokemon.tempSpeciesChange_originalSpecies = user.pokemon.species if !user.pokemon.tempSpeciesChange_originalSpecies
|
||||
user.pokemon.species = user.pokemon.tempSpeciesChange_originalSpecies
|
||||
|
||||
battle.pbShowAbilitySplash(target) if user.opposes?(target)
|
||||
head_species_number = GameData::Species.get(user.pokemon.species).get_head_species
|
||||
head_species = GameData::Species.get(head_species_number).id
|
||||
|
||||
|
||||
user.changeSpecies(user.pokemon, head_species, :MISSINGNO, "Paralysis")
|
||||
user.pbUpdate(true)
|
||||
oldAbil = user.ability
|
||||
user.ability = ability
|
||||
battle.scene.pbChangePokemon(user,user.pokemon)
|
||||
battle.scene.pbRefreshOne(user.index)
|
||||
end
|
||||
user.pbOnAbilityChanged(oldAbil) if oldAbil != nil
|
||||
battle.pbHideAbilitySplash(target) if user.opposes?(target)
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
BattleHandlers::TargetAbilityOnHit.add(:MUMMY,
|
||||
proc { |ability,user,target,move,battle|
|
||||
next if !move.pbContactMove?(user)
|
||||
|
||||
Reference in New Issue
Block a user