mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-08 21:54:58 +00:00
Fixed Pokémon-fusing items causing a fusion despite saying they
This commit is contained in:
@@ -955,6 +955,7 @@ ItemHandlers::UseOnPokemon.add(:DNASPLICERS,proc { |item,pkmn,scene|
|
|||||||
end
|
end
|
||||||
if pkmn.fainted?
|
if pkmn.fainted?
|
||||||
scene.pbDisplay(_INTL("This can't be used on the fainted Pokémon."))
|
scene.pbDisplay(_INTL("This can't be used on the fainted Pokémon."))
|
||||||
|
next false
|
||||||
end
|
end
|
||||||
# Fusing
|
# Fusing
|
||||||
if pkmn.fused==nil
|
if pkmn.fused==nil
|
||||||
@@ -963,13 +964,17 @@ ItemHandlers::UseOnPokemon.add(:DNASPLICERS,proc { |item,pkmn,scene|
|
|||||||
poke2 = $Trainer.party[chosen]
|
poke2 = $Trainer.party[chosen]
|
||||||
if pkmn==poke2
|
if pkmn==poke2
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with itself."))
|
scene.pbDisplay(_INTL("It cannot be fused with itself."))
|
||||||
|
next false
|
||||||
elsif poke2.egg?
|
elsif poke2.egg?
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with an Egg."))
|
scene.pbDisplay(_INTL("It cannot be fused with an Egg."))
|
||||||
|
next false
|
||||||
elsif poke2.fainted?
|
elsif poke2.fainted?
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with that fainted Pokémon."))
|
scene.pbDisplay(_INTL("It cannot be fused with that fainted Pokémon."))
|
||||||
|
next false
|
||||||
elsif !poke2.isSpecies?(:RESHIRAM) &&
|
elsif !poke2.isSpecies?(:RESHIRAM) &&
|
||||||
!poke2.isSpecies?(:ZEKROM)
|
!poke2.isSpecies?(:ZEKROM)
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with that Pokémon."))
|
scene.pbDisplay(_INTL("It cannot be fused with that Pokémon."))
|
||||||
|
next false
|
||||||
end
|
end
|
||||||
newForm = 0
|
newForm = 0
|
||||||
newForm = 1 if poke2.isSpecies?(:RESHIRAM)
|
newForm = 1 if poke2.isSpecies?(:RESHIRAM)
|
||||||
@@ -997,12 +1002,13 @@ ItemHandlers::UseOnPokemon.add(:DNASPLICERS,proc { |item,pkmn,scene|
|
|||||||
})
|
})
|
||||||
|
|
||||||
ItemHandlers::UseOnPokemon.add(:NSOLARIZER,proc { |item,pkmn,scene|
|
ItemHandlers::UseOnPokemon.add(:NSOLARIZER,proc { |item,pkmn,scene|
|
||||||
if !pkmn.isSpecies?(:NECROZMA) || pkmn.form==0
|
if !pkmn.isSpecies?(:NECROZMA) || pkmn.form == 2
|
||||||
scene.pbDisplay(_INTL("It had no effect."))
|
scene.pbDisplay(_INTL("It had no effect."))
|
||||||
next false
|
next false
|
||||||
end
|
end
|
||||||
if pkmn.fainted?
|
if pkmn.fainted?
|
||||||
scene.pbDisplay(_INTL("This can't be used on the fainted Pokémon."))
|
scene.pbDisplay(_INTL("This can't be used on the fainted Pokémon."))
|
||||||
|
next false
|
||||||
end
|
end
|
||||||
# Fusing
|
# Fusing
|
||||||
if pkmn.fused==nil
|
if pkmn.fused==nil
|
||||||
@@ -1011,12 +1017,16 @@ ItemHandlers::UseOnPokemon.add(:NSOLARIZER,proc { |item,pkmn,scene|
|
|||||||
poke2 = $Trainer.party[chosen]
|
poke2 = $Trainer.party[chosen]
|
||||||
if pkmn==poke2
|
if pkmn==poke2
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with itself."))
|
scene.pbDisplay(_INTL("It cannot be fused with itself."))
|
||||||
|
next false
|
||||||
elsif poke2.egg?
|
elsif poke2.egg?
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with an Egg."))
|
scene.pbDisplay(_INTL("It cannot be fused with an Egg."))
|
||||||
|
next false
|
||||||
elsif poke2.fainted?
|
elsif poke2.fainted?
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with that fainted Pokémon."))
|
scene.pbDisplay(_INTL("It cannot be fused with that fainted Pokémon."))
|
||||||
|
next false
|
||||||
elsif !poke2.isSpecies?(:SOLGALEO)
|
elsif !poke2.isSpecies?(:SOLGALEO)
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with that Pokémon."))
|
scene.pbDisplay(_INTL("It cannot be fused with that Pokémon."))
|
||||||
|
next false
|
||||||
end
|
end
|
||||||
pkmn.setForm(1) {
|
pkmn.setForm(1) {
|
||||||
pkmn.fused = poke2
|
pkmn.fused = poke2
|
||||||
@@ -1041,12 +1051,13 @@ ItemHandlers::UseOnPokemon.add(:NSOLARIZER,proc { |item,pkmn,scene|
|
|||||||
})
|
})
|
||||||
|
|
||||||
ItemHandlers::UseOnPokemon.add(:NLUNARIZER,proc { |item,pkmn,scene|
|
ItemHandlers::UseOnPokemon.add(:NLUNARIZER,proc { |item,pkmn,scene|
|
||||||
if !pkmn.isSpecies?(:NECROZMA) || pkmn.form==1
|
if !pkmn.isSpecies?(:NECROZMA) || pkmn.form == 1
|
||||||
scene.pbDisplay(_INTL("It had no effect."))
|
scene.pbDisplay(_INTL("It had no effect."))
|
||||||
next false
|
next false
|
||||||
end
|
end
|
||||||
if pkmn.fainted?
|
if pkmn.fainted?
|
||||||
scene.pbDisplay(_INTL("This can't be used on the fainted Pokémon."))
|
scene.pbDisplay(_INTL("This can't be used on the fainted Pokémon."))
|
||||||
|
next false
|
||||||
end
|
end
|
||||||
# Fusing
|
# Fusing
|
||||||
if pkmn.fused==nil
|
if pkmn.fused==nil
|
||||||
@@ -1055,12 +1066,16 @@ ItemHandlers::UseOnPokemon.add(:NLUNARIZER,proc { |item,pkmn,scene|
|
|||||||
poke2 = $Trainer.party[chosen]
|
poke2 = $Trainer.party[chosen]
|
||||||
if pkmn==poke2
|
if pkmn==poke2
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with itself."))
|
scene.pbDisplay(_INTL("It cannot be fused with itself."))
|
||||||
|
next false
|
||||||
elsif poke2.egg?
|
elsif poke2.egg?
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with an Egg."))
|
scene.pbDisplay(_INTL("It cannot be fused with an Egg."))
|
||||||
|
next false
|
||||||
elsif poke2.fainted?
|
elsif poke2.fainted?
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with that fainted Pokémon."))
|
scene.pbDisplay(_INTL("It cannot be fused with that fainted Pokémon."))
|
||||||
|
next false
|
||||||
elsif !poke2.isSpecies?(:LUNALA)
|
elsif !poke2.isSpecies?(:LUNALA)
|
||||||
scene.pbDisplay(_INTL("It cannot be fused with that Pokémon."))
|
scene.pbDisplay(_INTL("It cannot be fused with that Pokémon."))
|
||||||
|
next false
|
||||||
end
|
end
|
||||||
pkmn.setForm(2) {
|
pkmn.setForm(2) {
|
||||||
pkmn.fused = poke2
|
pkmn.fused = poke2
|
||||||
|
|||||||
@@ -368,7 +368,7 @@ def pbDebugMenuActions(cmd="",sprites=nil,viewport=nil)
|
|||||||
battle = pbListScreen(_INTL("SINGLE TRAINER"),TrainerBattleLister.new(0,false))
|
battle = pbListScreen(_INTL("SINGLE TRAINER"),TrainerBattleLister.new(0,false))
|
||||||
if battle
|
if battle
|
||||||
trainerdata = battle[1]
|
trainerdata = battle[1]
|
||||||
pbTrainerBattle(trainerdata[0],trainerdata[1],"...",false,trainerdata[4],true)
|
pbTrainerBattle(trainerdata[0],trainerdata[1],nil,false,trainerdata[4],true)
|
||||||
end
|
end
|
||||||
when "testtrainerbattleadvanced"
|
when "testtrainerbattleadvanced"
|
||||||
trainers = []
|
trainers = []
|
||||||
|
|||||||
Reference in New Issue
Block a user