Made Giratina's form use a map_metadata flag "DistortionWorld" instead of a hardcoded array of map numbers

This commit is contained in:
Maruno17
2021-12-21 19:12:19 +00:00
parent dfb3a51815
commit 6b3fa5e1bf
3 changed files with 9 additions and 6 deletions

View File

@@ -259,8 +259,9 @@ MultipleForms.register(:ROTOM, {
MultipleForms.register(:GIRATINA, {
"getForm" => proc { |pkmn|
maps = [49, 50, 51, 72, 73] # Map IDs for Origin Forme
if pkmn.hasItem?(:GRISEOUSORB) || ($game_map && maps.include?($game_map.map_id))
next 1 if pkmn.hasItem?(:GRISEOUSORB)
if $game_map &&
GameData::MapMetadata.get($game_map.map_id)&.has_flag?("DistortionWorld")
next 1
end
next 0