diff --git a/.DS_Store b/.DS_Store index 440ce0e0c..0f27d62db 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/Data/.DS_Store b/Data/.DS_Store index afe2aad13..6a21a50e6 100644 Binary files a/Data/.DS_Store and b/Data/.DS_Store differ diff --git a/Data/Scripts/.DS_Store b/Data/Scripts/.DS_Store index 7c7d74362..68be3b901 100644 Binary files a/Data/Scripts/.DS_Store and b/Data/Scripts/.DS_Store differ diff --git a/Data/Scripts/001_Settings.rb b/Data/Scripts/001_Settings.rb index cbb35bda7..ff90b8630 100644 --- a/Data/Scripts/001_Settings.rb +++ b/Data/Scripts/001_Settings.rb @@ -5,11 +5,11 @@ #==============================================================================# module Settings # The version of your game. It has to adhere to the MAJOR.MINOR.PATCH format. - GAME_VERSION_NUMBER = "6.9.1" - LATEST_GAME_RELEASE = "6.9.1" + GAME_VERSION_NUMBER = "6.9.2" + LATEST_GAME_RELEASE = "6.9.2" - HOENN_VERSION_NUMBER = "1.3" - HOENN_LATEST_GAME_RELEASE = "1.3.2" + HOENN_VERSION_NUMBER = "1.3.1" + HOENN_LATEST_GAME_RELEASE = "1.3.1" SNOW_DAY = true @@ -37,7 +37,7 @@ module Settings ANIMATE_REFLECTIONS = false # GAME_ID == :IF_HOENN #true USE_REFLECTIONS = false # Infinite fusion settings - NB_POKEMON = 576 + NB_POKEMON = 582 TRANSFER_BOX_DISCLAIMER_MESSAGE = "" CUSTOM_BASE_SPRITES_FOLDER = "Graphics/CustomBattlers/local_sprites/BaseSprites/" CUSTOM_BATTLERS_FOLDER = "Graphics/CustomBattlers/" diff --git a/Data/Scripts/001_Technical/000_Encryption.rb b/Data/Scripts/001_Technical/000_Encryption.rb index 6f44680cd..af3ce65cc 100644 --- a/Data/Scripts/001_Technical/000_Encryption.rb +++ b/Data/Scripts/001_Technical/000_Encryption.rb @@ -2,22 +2,7 @@ module Encryption ENCRYPTION_KEY = [0x4A, 0x8F, 0x2C, 0xE1, 0x73, 0xB5, 0x96, 0x0D, 0x5E, 0xA2, 0x3F, 0xC7, 0x81, 0x14, 0x6B, 0xD9] - CHUNK_SIZE = 1 << 20 - def self.xor(data) - key = ENCRYPTION_KEY.pack("C*") - @full_chunk_key ||= (key * (CHUNK_SIZE / key.length)).unpack1("H*").to_i(16) - full_chunk_key = @full_chunk_key - result = String.new(capacity: data.bytesize, encoding: Encoding::BINARY) - offset = 0 - while offset < data.bytesize - chunk = data.byteslice(offset, CHUNK_SIZE) - size = chunk.bytesize - chunk_key = size == CHUNK_SIZE ? full_chunk_key : (key * (size / key.length + 1)).byteslice(0, size).unpack1("H*").to_i(16) - xored = chunk.unpack1("H*").to_i(16) ^ chunk_key - result << [xored.to_s(16).rjust(size * 2, "0")].pack("H*") - offset += CHUNK_SIZE - end - return result + data.bytes.each_with_index.map { |b, i| b ^ ENCRYPTION_KEY[i % ENCRYPTION_KEY.length] }.pack("C*") end -end +end \ No newline at end of file diff --git a/Data/Scripts/001_Technical/003_Intl_Messages.rb b/Data/Scripts/001_Technical/003_Intl_Messages.rb index 4b9838461..ae0cb8d4b 100644 --- a/Data/Scripts/001_Technical/003_Intl_Messages.rb +++ b/Data/Scripts/001_Technical/003_Intl_Messages.rb @@ -548,7 +548,7 @@ class Messages @messages = [] if !@messages arr = [] for i in 0...array.length - arr[i] = (array[i] == "") ? nil : array[i] + arr[i] = (array[i]) ? array[i] : "" end @messages[type] = arr end @@ -557,8 +557,7 @@ class Messages @messages = [] if !@messages arr = (@messages[type]) ? @messages[type] : [] for i in 0...array.length - arr[i] = array[i] if array[i] - arr[i] = nil if arr[i] == "" + arr[i] = (array[i]) ? array[i] : (arr[i]) ? arr[i] : "" end @messages[type] = arr end @@ -766,10 +765,6 @@ module MessageTypes @@messages.loadMessageFile(filename) end - def self.loadFallbackMessageFile(filename) - @@messagesFallback.loadMessageFile(filename) - end - def self.get(type, id) ret = @@messages.get(type, id) if ret == "" diff --git a/Data/Scripts/010_Data/002_PBS data/013_Trainer.rb b/Data/Scripts/010_Data/002_PBS data/013_Trainer.rb index 9eff24ea2..4025c1212 100644 --- a/Data/Scripts/010_Data/002_PBS data/013_Trainer.rb +++ b/Data/Scripts/010_Data/002_PBS data/013_Trainer.rb @@ -202,7 +202,15 @@ module GameData def generateRandomChampionSpecies(old_species) customsList = getCustomSpeciesList() bst_range = pbGet(VAR_RANDOMIZER_TRAINER_BST) - new_species = $game_switches[SWITCH_RANDOM_GYM_CUSTOMS] ? getSpecies(getNewCustomSpecies(old_species, customsList, bst_range)) : getSpecies(getNewSpecies(old_species, bst_range)) + + same_egg_group = $game_switches[SWITCH_RANDOM_WILD_EGG_GROUP] + includeLegendaries = $game_switches[SWITCH_RANDOM_WILD_LEGENDARIES] + + if $game_switches[SWITCH_RANDOM_GYM_CUSTOMS] + new_species = getSpecies(getNewCustomSpecies(old_species, customsList, bst_range,false,includeLegendaries,same_egg_group)) + else + new_species = getSpecies(getNewSpecies(old_species, bst_range,false,PBSpecies.maxValue,includeLegendaries,same_egg_group)) + end #every pokemon should be fully evolved evolved_species_id = getEvolution(new_species) evolved_species_id = getEvolution(evolved_species_id) diff --git a/Data/Scripts/012_Overworld/001_Overworld visuals/003_Overworld_MapTransitionAnims.rb b/Data/Scripts/012_Overworld/001_Overworld visuals/003_Overworld_MapTransitionAnims.rb index 70f34a702..64b48b7ea 100644 --- a/Data/Scripts/012_Overworld/001_Overworld visuals/003_Overworld_MapTransitionAnims.rb +++ b/Data/Scripts/012_Overworld/001_Overworld visuals/003_Overworld_MapTransitionAnims.rb @@ -101,7 +101,6 @@ def pbStartOver(gameover = false) if Settings::HOENN $game_switches[SWITCH_RIVAL_ON_MT_CHIMNEY] = false $game_switches[SWITCH_WAILMER_EGGS_QUEST] = false - $game_variables[] end diff --git a/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb b/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb index eeab00ac3..f2daf1429 100644 --- a/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb +++ b/Data/Scripts/012_Overworld/004_Overworld_FieldMoves.rb @@ -419,7 +419,6 @@ end # Dive #=============================================================================== def pbDive - return return false if $game_player.pbFacingEvent map_metadata = GameData::MapMetadata.try_get($game_map.map_id) return false if !map_metadata || !map_metadata.dive_map_id diff --git a/Data/Scripts/025-Randomizer/randomizer gym leader edit.rb b/Data/Scripts/025-Randomizer/randomizer gym leader edit.rb index d3da21a3b..0b2aa3f5e 100644 --- a/Data/Scripts/025-Randomizer/randomizer gym leader edit.rb +++ b/Data/Scripts/025-Randomizer/randomizer gym leader edit.rb @@ -356,7 +356,7 @@ def new_legendary_cache Hash.new { |h, sp| h[sp] = is_legendary_num(sp) } end -def getNewCustomSpecies(oldSpecies, customSpeciesList, bst_range, ignoreRivalPlaceholder, includeLegendaries, same_egg_group, +def getNewCustomSpecies(oldSpecies, customSpeciesList, bst_range, ignoreRivalPlaceholder=false, includeLegendaries=true, same_egg_group=false, bst_cache = nil, egg_group_cache = nil, legendary_cache = nil, fallback_cache = nil) if $game_switches[SWITCH_LEGENDARY_MODE] return dexNum(convert_species_to_legendary(oldSpecies)) diff --git a/Data/Scripts/052_InfiniteFusion/Menus/Movie.rb b/Data/Scripts/052_InfiniteFusion/Menus/Movie.rb index 6a37c8f53..c2ce96b3f 100644 --- a/Data/Scripts/052_InfiniteFusion/Menus/Movie.rb +++ b/Data/Scripts/052_InfiniteFusion/Menus/Movie.rb @@ -48,7 +48,6 @@ class Movie picture.bitmap = pbBitmap(frame) picture.visible=true pbWait(Graphics.frame_rate / 20) - picture.bitmap&.dispose picture.dispose @currentFrame += 1 end diff --git a/Data/Scripts/999_Main/999_Main.rb b/Data/Scripts/999_Main/999_Main.rb index 770c793ca..bdab9c11b 100644 --- a/Data/Scripts/999_Main/999_Main.rb +++ b/Data/Scripts/999_Main/999_Main.rb @@ -168,7 +168,7 @@ end def mainFunctionDebug begin showLoadingScreen - MessageTypes.loadFallbackMessageFile("Data/messages.dat") if safeExists?("Data/messages.dat") + MessageTypes.loadMessageFile("Data/messages.dat") if safeExists?("Data/messages.dat") PluginManager.runPlugins Compiler.main Game.initialize diff --git a/Data/Scripts/DownloadedSettings.rb b/Data/Scripts/DownloadedSettings.rb index 8913b7644..ff9182f16 100644 --- a/Data/Scripts/DownloadedSettings.rb +++ b/Data/Scripts/DownloadedSettings.rb @@ -9,16 +9,15 @@ module Settings ALTERING_CAVE_ENCOUNTERS = { - :MONDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :PHANTUMP], - :TUESDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :STANTLER], - :WEDNESDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :GASTLY], - :THURSDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :MIMIKYU], - :FRIDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :HOOTHOOT], - :SATURDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :PUMPKABOO], - :SUNDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :MISDREAVUS], + :MONDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :HOUNDOUR], + :TUESDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :SCRAGGY], + :WEDNESDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :PINECO], + :THURSDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :MAREEP], + :FRIDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :TEDDIURSA], + :SATURDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :AIPOM], + :SUNDAY => [:ZUBAT, :ZUBAT, :ZUBAT, :WOOBAT, :SMEARGLE], } - STARTUP_MESSAGES = "Pokémon Infinite Fusion 2 is now available! Download it from the game's Discord!" #Legacy starting PIF1 6.8 STARTUP_MESSAGES_KANTO = "Pokémon Infinite Fusion 2 is now available! Download it from the game's Discord!" STARTUP_MESSAGES_HOENN = "Pokémon Infinite Fusion 2 is still in development. Make sure to restart the game once in a while if you experience any lag issues." diff --git a/Graphics/Characters/.DS_Store b/Graphics/Characters/.DS_Store index d8cfa55b1..43c1473e3 100644 Binary files a/Graphics/Characters/.DS_Store and b/Graphics/Characters/.DS_Store differ