diff --git a/Data/Scripts/011_Battle/001_Battler/007_Battler_UseMove.rb b/Data/Scripts/011_Battle/001_Battler/007_Battler_UseMove.rb index 5ed498a85..9b5b44903 100644 --- a/Data/Scripts/011_Battle/001_Battler/007_Battler_UseMove.rb +++ b/Data/Scripts/011_Battle/001_Battler/007_Battler_UseMove.rb @@ -624,27 +624,8 @@ class PokeBattle_Battler #For meloetta form change def changeFormSpecies(oldForm, newForm,animation = "UltraBurst2") - @pokemon.changeFormSpecies(oldForm,newForm) playChangeFormAnimation(animation) - - # is_already_old_form = @pokemon.isFusionOf(oldForm) #A 466 - # is_already_new_form = @pokemon.isFusionOf(newForm) #P - # - # - # #reverse the fusion if it's a meloA and meloP fusion - # # There's probably a smarter way to do this but laziness lol - # if is_already_old_form && is_already_new_form - # if @pokemon.species_data.get_body_species() == oldForm - # changeSpeciesSpecific(@pokemon,getFusedPokemonIdFromSymbols(newForm,oldForm)) - # else - # changeSpeciesSpecific(@pokemon,getFusedPokemonIdFromSymbols(oldForm,newForm)) - # end - # playChangeFormAnimation(animation) - # else - # changeSpecies(@pokemon, oldForm, newForm, animation) if is_already_old_form - # changeSpecies(@pokemon, newForm, oldForm, animation) if is_already_new_form - # end end diff --git a/Data/Scripts/011_Battle/002_Move/005_Move_Effects_000-07F.rb b/Data/Scripts/011_Battle/002_Move/005_Move_Effects_000-07F.rb index 0519e3ba2..e957e22b9 100644 --- a/Data/Scripts/011_Battle/002_Move/005_Move_Effects_000-07F.rb +++ b/Data/Scripts/011_Battle/002_Move/005_Move_Effects_000-07F.rb @@ -49,7 +49,9 @@ class PokeBattle_Move_003 < PokeBattle_SleepMove #reverse the fusion if it's a meloA and meloP fusion # There's probably a smarter way to do this but laziness lol if is_meloetta_A && is_meloetta_P - if user.pokemon.species_data.get_body_species() == :MELOETTA_A + body_id = user.pokemon.species_data.get_body_species() + body_species = GameData::Species.get(body_id) + if body_species == :MELOETTA_A changeSpeciesSpecific(user.pokemon,:B467H466) else changeSpeciesSpecific(user.pokemon,:B466H467) diff --git a/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb b/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb index b7e8265a8..8857f6a96 100644 --- a/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb +++ b/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb @@ -677,7 +677,9 @@ def changeMeloettaForm(pokemon) return end if is_meloetta_A && is_meloetta_P - if pokemon.species_data.get_body_species() == :MELOETTA_A + body_id = pokemon.species_data.get_body_species() + body_species = GameData::Species.get(body_id) + if body_species == :MELOETTA_A changeSpeciesSpecific(pokemon, :B467H466) else changeSpeciesSpecific(pokemon, :B466H467) diff --git a/Data/Scripts/014_Pokemon/001_Pokemon.rb b/Data/Scripts/014_Pokemon/001_Pokemon.rb index d35bc60b1..0df4e4ef1 100644 --- a/Data/Scripts/014_Pokemon/001_Pokemon.rb +++ b/Data/Scripts/014_Pokemon/001_Pokemon.rb @@ -341,7 +341,10 @@ class Pokemon #reverse the fusion if it's a meloA and meloP fusion # There's probably a smarter way to do this but laziness lol if is_already_old_form && is_already_new_form - if self.species_data.get_body_species() == oldForm + body_id = self.species_data.get_body_species() + body_species = GameData::Species.get(body_id) + + if body_species == oldForm changeSpeciesSpecific(self, getFusedPokemonIdFromSymbols(newForm, oldForm)) else changeSpeciesSpecific(self, getFusedPokemonIdFromSymbols(oldForm, newForm))