Compare commits
57 Commits
release-6.
...
6.0.5
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5636c12408 | ||
|
|
869ffbc1a3 | ||
|
|
2294fddcdd | ||
|
|
170b893d99 | ||
|
|
602b5d9752 | ||
|
|
ba6f7f3ab2 | ||
|
|
a5311f5e2d | ||
|
|
e6e53bc94b | ||
|
|
d9098afbec | ||
|
|
9aee5206cd | ||
|
|
e1c52d9546 | ||
|
|
0433e49477 | ||
|
|
6f8f478303 | ||
|
|
5f09bec5ff | ||
|
|
e7629a8afa | ||
|
|
1af9d853cb | ||
|
|
cbe71d8530 | ||
|
|
9ade3e829a | ||
|
|
8f91ba0ff5 | ||
|
|
0713ed0bb5 | ||
|
|
1d2ccb781b | ||
|
|
081fa99293 | ||
|
|
179c8d078b | ||
|
|
48327a61ff | ||
|
|
6e5f7bbce2 | ||
|
|
7bfaec31f2 | ||
|
|
9a507fe4c1 | ||
|
|
50cf18417e | ||
|
|
4d74cc7943 | ||
|
|
1acc5ef4f7 | ||
|
|
3943ce1684 | ||
|
|
433cb999ff | ||
|
|
ea84f0fe2d | ||
|
|
44dc443a6c | ||
|
|
e4ae8802d5 | ||
|
|
e292078d17 | ||
|
|
2635217407 | ||
|
|
d729a630e5 | ||
|
|
b8f1162bd8 | ||
|
|
d941ae48e9 | ||
|
|
a86b844649 | ||
|
|
cfc76d1f77 | ||
|
|
5ab7074507 | ||
|
|
62b588314e | ||
|
|
0b334fe3ea | ||
|
|
b79f4b2f93 | ||
|
|
2af97a0bbf | ||
|
|
959edc3f6a | ||
|
|
91153181c3 | ||
|
|
d3662c3f10 | ||
|
|
ba7ee9bae2 | ||
|
|
a0aea8f030 | ||
|
|
6ba975ac51 | ||
|
|
2dd2a5d33b | ||
|
|
1ea6b531c2 | ||
|
|
b600e126bc | ||
|
|
2411a0c9fc |
9
.gitignore
vendored
@@ -0,0 +1,9 @@
|
||||
Graphics/Battlers/*
|
||||
PBS/*
|
||||
Graphics/Battlers_resized/*
|
||||
Graphics/CustomBattlers/*
|
||||
Graphics/Pokemon/FusionIcons/*
|
||||
Data/SPRITE_CREDS
|
||||
Data/VERSION
|
||||
Exported Maps/*
|
||||
Game.rxproj
|
||||
|
||||
BIN
Data/Map816.rxdata
Normal file
24025
Data/SPRITE_CREDS
@@ -6,7 +6,7 @@
|
||||
module Settings
|
||||
# The version of your game. It has to adhere to the MAJOR.MINOR.PATCH format.
|
||||
GAME_VERSION = '5.0.0'
|
||||
GAME_VERSION_NUMBER = "6.0"
|
||||
GAME_VERSION_NUMBER = "6.0.5"
|
||||
|
||||
POKERADAR_LIGHT_ANIMATION_RED_ID = 17
|
||||
POKERADAR_LIGHT_ANIMATION_GREEN_ID = 18
|
||||
@@ -34,7 +34,7 @@ module Settings
|
||||
HTTP_CONFIGS_FILE_URL = "https://raw.githubusercontent.com/infinitefusion/infinitefusion-e18/main/Data/Scripts/RemoteUrls.rb"
|
||||
HTTP_CONFIGS_FILE_PATH = "Data/Scripts/DownloadedSettings.rb"
|
||||
|
||||
LEVEL_CAPS=[12,22,26,35,38,45,51,54,58,62,63,64,64,65,67,68]
|
||||
LEVEL_CAPS=[12,22,26,35,38,45,51,54,62,62,63,64,64,65,67,68]
|
||||
|
||||
FRONTSPRITE_POSITION_OFFSET = 20
|
||||
FRONTSPRITE_SCALE = 0.6666666666666666
|
||||
|
||||
@@ -17,6 +17,11 @@ module GameData
|
||||
validate other => [Symbol, self, String, Integer]
|
||||
other = other.id if other.is_a?(self)
|
||||
other = other.to_sym if other.is_a?(String)
|
||||
|
||||
if self == GameData::Species
|
||||
return !get(other).nil?
|
||||
end
|
||||
|
||||
return !self::DATA[other].nil?
|
||||
end
|
||||
|
||||
@@ -43,7 +48,7 @@ module GameData
|
||||
end
|
||||
|
||||
if !self::DATA.has_key?(other)
|
||||
echo _INTL("Unknown ID {1}.", other)
|
||||
echoln _INTL("Unknown ID {1}.", other)
|
||||
return self::get(:PIKACHU)
|
||||
end
|
||||
|
||||
|
||||
@@ -154,7 +154,9 @@ module GameData
|
||||
end
|
||||
if $game_switches[SWITCH_RANDOM_GYM_PERSIST_TEAMS] && $PokemonGlobal.randomGymTrainersHash != nil
|
||||
if $PokemonGlobal.randomGymTrainersHash[trainerId] != nil && $PokemonGlobal.randomGymTrainersHash[trainerId].length >= $PokemonGlobal.randomTrainersHash[trainerId].length
|
||||
return getSpecies($PokemonGlobal.randomGymTrainersHash[trainerId][pokemonIndex])
|
||||
newSpecies = getSpecies($PokemonGlobal.randomGymTrainersHash[trainerId][pokemonIndex])
|
||||
return newSpecies if newSpecies
|
||||
return species
|
||||
end
|
||||
end
|
||||
new_species = generateRandomGymSpecies(species)
|
||||
@@ -198,6 +200,7 @@ module GameData
|
||||
|
||||
def replace_species_to_randomized(species, trainerId, pokemonIndex)
|
||||
return species if $game_switches[SWITCH_FIRST_RIVAL_BATTLE]
|
||||
return species if getDexNumberForSpecies(species) >= Settings::ZAPMOLCUNO_NB
|
||||
if isGymBattle() && $game_switches[SWITCH_RANDOMIZE_GYMS_SEPARATELY]
|
||||
return replace_species_to_randomized_gym(species, trainerId, pokemonIndex)
|
||||
end
|
||||
|
||||
@@ -595,10 +595,16 @@ class PokeBattle_Battler
|
||||
end
|
||||
end
|
||||
|
||||
def ensure_form_has_sprite(pokemon,spriteform_body,spriteform_head)
|
||||
GameData::Species.sprite_filename(pokemon.dexNum, spriteform_body,spriteform_head)
|
||||
end
|
||||
|
||||
def changeForm(newForm, formChangingSpecies, animation = "UltraBurst2")
|
||||
spriteform_body = newForm if @pokemon.hasBodyOf?(formChangingSpecies)
|
||||
spriteform_head = newForm if @pokemon.hasHeadOf?(formChangingSpecies)
|
||||
|
||||
ensure_form_has_sprite(@pokemon,spriteform_body,spriteform_head)
|
||||
|
||||
if self.isFusion?
|
||||
current_form_has_custom = customSpriteExists(@pokemon.species)
|
||||
new_form_has_custom = customSpriteExistsForm(@pokemon.species, spriteform_head, spriteform_body)
|
||||
@@ -607,7 +613,6 @@ class PokeBattle_Battler
|
||||
should_change_sprite=true
|
||||
end
|
||||
|
||||
|
||||
if should_change_sprite
|
||||
@pokemon.spriteform_body = spriteform_body
|
||||
@pokemon.spriteform_head = spriteform_head
|
||||
|
||||
@@ -63,20 +63,31 @@ class PokemonDataBox < SpriteWrapper
|
||||
# Determine the co-ordinates of the data box and the left edge padding width
|
||||
if onPlayerSide
|
||||
@spriteX = Graphics.width - 244
|
||||
@spriteY = Graphics.height - 192
|
||||
@spriteY = Graphics.height - 176#192
|
||||
@spriteBaseX = 34
|
||||
else
|
||||
@spriteX = 8 #-16
|
||||
@spriteY = 36
|
||||
@spriteY = 0##36
|
||||
@spriteBaseX = 8 #16
|
||||
end
|
||||
case sideSize
|
||||
when 2
|
||||
|
||||
|
||||
@spriteX += [-12, 12, 0, 0][@battler.index]
|
||||
@spriteY += [-20, -34, 34, 20][@battler.index]
|
||||
|
||||
#@spriteY += [-38, -6, 16, 48][@battler.index] #standard
|
||||
#@spriteY += [-32, -6, 16, 42][@battler.index] #smaller gap
|
||||
@spriteY += [-18, -6, 16, 28][@battler.index] #overlap
|
||||
|
||||
|
||||
|
||||
#@spriteY += [-20, -34, 34, 20][@battler.index]
|
||||
when 3
|
||||
@spriteX += [-12, 12, -6, 6, 0, 0][@battler.index]
|
||||
@spriteY += [-42, -46, 4, 0, 50, 46][@battler.index]
|
||||
#@spriteY += [-74, -8, -28, 38, 16, 84][@battler.index] #standard
|
||||
@spriteY += [-54, -8, -18, 26, 16, 58][@battler.index] #overlap
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -82,6 +82,7 @@ end
|
||||
# Blacking out animation
|
||||
#===============================================================================
|
||||
def pbStartOver(gameover=false)
|
||||
$game_variables[VAR_CURRENT_GYM_TYPE]=-1
|
||||
if pbInBugContest?
|
||||
pbBugContestStartOver
|
||||
return
|
||||
|
||||
@@ -336,11 +336,19 @@ end
|
||||
#===============================================================================
|
||||
# Used when walking in tall grass, hence the additional code.
|
||||
def pbWildBattle(species, level, outcomeVar=1, canRun=true, canLose=false)
|
||||
if !species
|
||||
displayRandomizerErrorMessage()
|
||||
return
|
||||
end
|
||||
species = GameData::Species.get(species).id
|
||||
dexnum = getDexNumberForSpecies(species)
|
||||
if $game_switches[SWITCH_RANDOM_STATIC_ENCOUNTERS] && dexnum <= NB_POKEMON
|
||||
newSpecies = $PokemonGlobal.psuedoBSTHash[dexnum]
|
||||
species = getSpecies(newSpecies)
|
||||
if !newSpecies
|
||||
displayRandomizerErrorMessage()
|
||||
else
|
||||
species = getSpecies(newSpecies)
|
||||
end
|
||||
end
|
||||
|
||||
# Potentially call a different pbWildBattle-type method instead (for roaming
|
||||
|
||||
@@ -1084,10 +1084,10 @@ ItemHandlers::UseOnPokemon.add(:ABILITYCAPSULE, proc { |item, pkmn, scene|
|
||||
})
|
||||
|
||||
|
||||
ItemHandlers::UseInField.add(:REGITABLET, proc { |item|
|
||||
pbCommonEvent(COMMON_EVENT_REGI_TABLET)
|
||||
next true
|
||||
})
|
||||
# ItemHandlers::UseInField.add(:REGITABLET, proc { |item|
|
||||
# pbCommonEvent(COMMON_EVENT_REGI_TABLET)
|
||||
# next true
|
||||
# })
|
||||
|
||||
ItemHandlers::UseFromBag.add(:POKERADAR, proc { |item|
|
||||
next (pbCanUsePokeRadar?) ? 2 : 0
|
||||
|
||||
@@ -61,9 +61,9 @@ class PokeRadar_UI
|
||||
|
||||
def addPokemonIcon(species, blackened = false, rare=false)
|
||||
pokemonId=dexNum(species)
|
||||
iconId = _INTL("icon{1}", pokemonId)
|
||||
iconId = _INTL("{1}", species)
|
||||
|
||||
pokemonBitmap = pbCheckPokemonIconFiles(getDexNumberForSpecies(pokemonId))
|
||||
pokemonBitmap = pbCheckPokemonIconFiles(species)
|
||||
|
||||
if rare
|
||||
outlineSprite = IconSprite.new(@current_x, @current_y)
|
||||
|
||||
@@ -229,7 +229,7 @@ class PokemonStorage
|
||||
def pbStoreCaught(pkmn)
|
||||
if @currentBox>=0
|
||||
pkmn.time_form_set = nil
|
||||
pkmn.form = 0 if pkmn.isSpecies?(:SHAYMIN)
|
||||
#pkmn.form = 0 if pkmn.isSpecies?(:SHAYMIN)
|
||||
#pkmn.heal
|
||||
end
|
||||
for i in 0...maxPokemon(@currentBox)
|
||||
|
||||
@@ -1038,7 +1038,12 @@ class PokemonPokedex_Scene
|
||||
_INTL("U"),_INTL("V"),_INTL("W"),_INTL("X"),_INTL("Y"),
|
||||
_INTL("Z")]
|
||||
@typeCommands = []
|
||||
GameData::Type.each { |t| @typeCommands.push(t) if !t.pseudo_type }
|
||||
|
||||
count = 0
|
||||
GameData::Type.each do |t|
|
||||
@typeCommands.push(t) if !t.pseudo_type && count <= 18
|
||||
count +=1
|
||||
end
|
||||
@typeCommands.sort! { |a, b| a.id_number <=> b.id_number }
|
||||
@heightCommands = [1,2,3,4,5,6,7,8,9,10,
|
||||
11,12,13,14,15,16,17,18,19,20,
|
||||
|
||||
@@ -1932,7 +1932,7 @@ class PokemonStorageScreen
|
||||
if heldpoke || selected[0] == -1
|
||||
p = (heldpoke) ? heldpoke : @storage[-1, index]
|
||||
p.time_form_set = nil
|
||||
p.form = 0 if p.isSpecies?(:SHAYMIN)
|
||||
#p.form = 0 if p.isSpecies?(:SHAYMIN)
|
||||
#p.heal
|
||||
end
|
||||
@scene.pbStore(selected, heldpoke, destbox, firstfree)
|
||||
@@ -1967,7 +1967,9 @@ class PokemonStorageScreen
|
||||
box = selected[0]
|
||||
index = selected[1]
|
||||
if @storage[box, index]
|
||||
raise _INTL("Position {1},{2} is not empty...", box, index)
|
||||
pbDisplay("Can't place that there.")
|
||||
return
|
||||
echoln _INTL("Position {1},{2} is not empty...", box, index)
|
||||
end
|
||||
if box != -1 && index >= @storage.maxPokemon(box)
|
||||
pbDisplay("Can't place that there.")
|
||||
@@ -2319,7 +2321,7 @@ class PokemonStorageScreen
|
||||
|
||||
if (Kernel.pbConfirmMessage(_INTL("Fuse the two Pokémon?")))
|
||||
playingBGM = $game_system.getPlayingBGM
|
||||
pbFuse(selectedHead, selectedBase, isSuperSplicer)
|
||||
pbFuse(selectedHead, selectedBase, @fusionItem)
|
||||
if canDeleteItem(@fusionItem)
|
||||
$PokemonBag.pbDeleteItem(@fusionItem)
|
||||
end
|
||||
|
||||
@@ -127,7 +127,7 @@ def bstOk(newspecies, oldPokemonSpecies, bst_range = 50)
|
||||
end
|
||||
|
||||
def gymLeaderOk(newspecies)
|
||||
return true if $game_variables[152] == -1 #not in a gym
|
||||
return true if $game_variables[VAR_CURRENT_GYM_TYPE] == -1 #not in a gym
|
||||
leaderType = getLeaderType()
|
||||
if leaderType == nil
|
||||
return true
|
||||
@@ -138,7 +138,7 @@ def gymLeaderOk(newspecies)
|
||||
end
|
||||
|
||||
def getLeaderType()
|
||||
currentGym = $game_variables[152]
|
||||
currentGym = $game_variables[VAR_CURRENT_GYM_TYPE]
|
||||
if currentGym > $game_variables[151].length
|
||||
return nil
|
||||
else
|
||||
|
||||
@@ -285,11 +285,11 @@ module GameData
|
||||
["Garde", "voir"],
|
||||
["Sur", "skit"],
|
||||
["Masque", "rain"],
|
||||
["Shroom", "mish"],
|
||||
["Bre", "reloom"],
|
||||
["Sla", "oth"],
|
||||
["Vigor", "roth"],
|
||||
["Slak", "aking"],
|
||||
["Shroom", "ish"],
|
||||
["Bre", "loom"],
|
||||
["Sla", "koth"],
|
||||
["Vigo", "roth"],
|
||||
["Sla", "king"],
|
||||
["Nin", "cada"],
|
||||
["Nin", "jask"],
|
||||
["Shed", "inja"],
|
||||
@@ -299,7 +299,7 @@ module GameData
|
||||
["Maku", "hita"],
|
||||
["Hari", "yama"],
|
||||
["Azu", "rill"],
|
||||
["Nose", "ass"],
|
||||
["Nose", "pass"],
|
||||
["Skit", "itty"],
|
||||
["Del", "catty"],
|
||||
["Sabl", "eye"],
|
||||
@@ -387,19 +387,19 @@ module GameData
|
||||
["Ray", "quaza"],
|
||||
["Ji", "rachi"],
|
||||
["Deo", "xys"],
|
||||
["Turt", "wig"],
|
||||
["Gro", "otle"],
|
||||
["Tort", "terra"],
|
||||
["Tur", "wig"],
|
||||
["Gro", "tle"],
|
||||
["Tor", "terra"],
|
||||
["Chim", "char"],
|
||||
["Mon", "ferno"],
|
||||
["Infern", "nape"],
|
||||
["Infer", "nape"],
|
||||
["Pip", "lup"],
|
||||
["Prin", "plup"],
|
||||
["Empo", "leon"],
|
||||
["Starl", "arly"],
|
||||
["Starav", "avia"],
|
||||
["Starap", "raptor"],
|
||||
["Bid", "doof"],
|
||||
["Bi", "doof"],
|
||||
["Biba", "rel"],
|
||||
["Kri", "ketot"],
|
||||
["Kricke", "tune"],
|
||||
@@ -409,8 +409,8 @@ module GameData
|
||||
["Bu", "dew"],
|
||||
["Rose", "rade"],
|
||||
["Cran", "idos"],
|
||||
["Ramp", "pardos"],
|
||||
["Shield", "don"],
|
||||
["Ram", "pardos"],
|
||||
["Shiel", "don"],
|
||||
["Bastio", "don"],
|
||||
["Bur", "my"],
|
||||
["Worma", "dam"],
|
||||
|
||||
@@ -257,7 +257,18 @@ def record_sprite_substitution(substitution_id, sprite_name)
|
||||
$PokemonGlobal.alt_sprite_substitutions[substitution_id] = sprite_name
|
||||
end
|
||||
|
||||
def add_to_autogen_cache(pokemon_id, sprite_name)
|
||||
return if !$PokemonGlobal
|
||||
return if !$PokemonGlobal.autogen_sprites_cache
|
||||
$PokemonGlobal.autogen_sprites_cache[pokemon_id]=sprite_name
|
||||
end
|
||||
|
||||
class PokemonGlobalMetadata
|
||||
attr_accessor :autogen_sprites_cache
|
||||
end
|
||||
|
||||
def get_fusion_sprite_path(head_id, body_id, spriteform_body = nil, spriteform_head = nil)
|
||||
$PokemonGlobal.autogen_sprites_cache = {} if $PokemonGlobal && !$PokemonGlobal.autogen_sprites_cache
|
||||
#Todo: ça va chier si on fusionne une forme d'un pokemon avec une autre forme, mais pas un problème pour tout de suite
|
||||
form_suffix = ""
|
||||
form_suffix += "_" + spriteform_body.to_s if spriteform_body
|
||||
@@ -286,6 +297,9 @@ def get_fusion_sprite_path(head_id, body_id, spriteform_body = nil, spriteform_h
|
||||
record_sprite_substitution(substitution_id, local_custom_path)
|
||||
return local_custom_path
|
||||
end
|
||||
#if the game has loaded an autogen earlier, no point in trying to redownload, so load that instead
|
||||
return $PokemonGlobal.autogen_sprites_cache[substitution_id] if $PokemonGlobal && $PokemonGlobal.autogen_sprites_cache[substitution_id]
|
||||
|
||||
#Try to download custom sprite if none found locally
|
||||
downloaded_custom = download_custom_sprite(head_id, body_id, spriteform_body_letter, spriteform_head_letter, random_alt)
|
||||
if downloaded_custom
|
||||
@@ -295,11 +309,17 @@ def get_fusion_sprite_path(head_id, body_id, spriteform_body = nil, spriteform_h
|
||||
|
||||
#Try local generated sprite
|
||||
local_generated_path = Settings::BATTLERS_FOLDER + head_id.to_s + spriteform_head_letter + "/" + filename
|
||||
return local_generated_path if pbResolveBitmap(local_generated_path)
|
||||
if pbResolveBitmap(local_generated_path)
|
||||
add_to_autogen_cache(substitution_id,local_generated_path)
|
||||
return local_generated_path
|
||||
end
|
||||
|
||||
#Download generated sprite if nothing else found
|
||||
autogen_path = download_autogen_sprite(head_id, body_id)
|
||||
return autogen_path if pbResolveBitmap(autogen_path)
|
||||
autogen_path = download_autogen_sprite(head_id, body_id,spriteform_body,spriteform_head)
|
||||
if pbResolveBitmap(autogen_path)
|
||||
add_to_autogen_cache(substitution_id,autogen_path)
|
||||
return autogen_path
|
||||
end
|
||||
|
||||
return Settings::DEFAULT_SPRITE_PATH
|
||||
end
|
||||
|
||||
@@ -141,7 +141,6 @@ def getFossilsGuyTeam(level)
|
||||
elsif $game_switches[SWITCH_PICKED_ANORITH_FOSSIL]
|
||||
fossils << :LILEEP if level < fossils_evolution_level_1
|
||||
fossils << :CRADILY if level >= fossils_evolution_level_1
|
||||
|
||||
end
|
||||
#Celadon fossil
|
||||
if $game_switches[SWITCH_PICKED_ARMOR_FOSSIL]
|
||||
@@ -211,9 +210,8 @@ end
|
||||
|
||||
def restoreDefaultCharacterSprite(charset_number=0)
|
||||
meta = GameData::Metadata.get_player($Trainer.character_ID)
|
||||
charset = pbGetPlayerCharset(meta,charset_number)
|
||||
|
||||
$game_player.setDefaultCharName(charset, 0, false)
|
||||
$game_player.setDefaultCharName(nil, 0, false)
|
||||
$game_player.character_name =meta[1]
|
||||
Graphics.update
|
||||
Input.update
|
||||
pbUpdateSceneMap
|
||||
@@ -584,7 +582,13 @@ def getMtMoonDirection()
|
||||
143, #Route 23
|
||||
167, #Crimson city
|
||||
]
|
||||
maps_west = []
|
||||
maps_west = [
|
||||
106, #route 4
|
||||
1, #cerulean
|
||||
495, #route 9
|
||||
351, #route 9
|
||||
10 #cerulean cape
|
||||
]
|
||||
return 2 if maps_south.include?($game_map.map_id)
|
||||
return 4 if maps_west.include?($game_map.map_id)
|
||||
return 6 if maps_east.include?($game_map.map_id)
|
||||
@@ -611,6 +615,15 @@ def validate_regirock_ice_puzzle(solution)
|
||||
return true
|
||||
end
|
||||
|
||||
def unpress_all_regirock_steel_switches()
|
||||
switch_ids = [75,77,76,67, 74,68, 73,72,70,69]
|
||||
regi_map = 813
|
||||
switch_ids.each do |event_id|
|
||||
pbSetSelfSwitch(event_id,"A",false,regi_map)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def validate_regirock_steel_puzzle()
|
||||
expected_pressed_switches = [75,77,74,68,73,69]
|
||||
expected_unpressed_switches = [76,67,72,70]
|
||||
@@ -618,7 +631,6 @@ def validate_regirock_steel_puzzle()
|
||||
74,68,
|
||||
73,72,70,69]
|
||||
|
||||
|
||||
pressed_switches =[]
|
||||
unpressed_switches = []
|
||||
switch_ids.each do |switch_id|
|
||||
@@ -695,8 +707,11 @@ def regirock_steel_move_boulder()
|
||||
pbSEPlay("Entering Door")
|
||||
pbSetSelfSwitch(switch_event.id, "A", true) if switch_event
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
|
||||
|
||||
def displayRandomizerErrorMessage()
|
||||
Kernel.pbMessage(_INTL("The randomizer has encountered an error. You should try to re-randomize your game as soon as possible."))
|
||||
Kernel.pbMessage(_INTL("You can do this on the top floor of Pokémon Centers."))
|
||||
end
|
||||
|
||||
|
||||
@@ -130,6 +130,7 @@ end
|
||||
|
||||
#in: pokemon number
|
||||
def Kernel.isPartPokemon(src, target)
|
||||
|
||||
src = getDexNumberForSpecies(src)
|
||||
target = getDexNumberForSpecies(target)
|
||||
return true if src == target
|
||||
@@ -150,6 +151,8 @@ def getBasePokemonID(pokemon, body = true)
|
||||
pokemon = dex_number
|
||||
end
|
||||
return nil if pokemon <= 0
|
||||
return nil if pokemon >= Settings::ZAPMOLCUNO_NB
|
||||
|
||||
# cname = getConstantName(PBSpecies, pokemon) rescue nil
|
||||
cname = GameData::Species.get(pokemon).id.to_s
|
||||
return pokemon if pokemon <= NB_POKEMON
|
||||
|
||||
@@ -118,12 +118,12 @@ def pbPokemonIconFile(pokemon)
|
||||
return bitmapFileName
|
||||
end
|
||||
|
||||
def pbCheckPokemonIconFiles(speciesNum, egg = false, dna = false)
|
||||
def pbCheckPokemonIconFiles(speciesID, egg = false, dna = false)
|
||||
if egg
|
||||
bitmapFileName = sprintf("Graphics/Icons/iconEgg")
|
||||
return pbResolveBitmap(bitmapFileName)
|
||||
else
|
||||
bitmapFileName = sprintf("Graphics/Icons/icon%03d", speciesNum)
|
||||
bitmapFileName = _INTL("Graphics/Pokemon/Icons/{1}", speciesID)
|
||||
ret = pbResolveBitmap(bitmapFileName)
|
||||
return ret if ret
|
||||
end
|
||||
@@ -410,6 +410,38 @@ def generateSimpleTrainerParty(teamSpecies, level)
|
||||
return team
|
||||
end
|
||||
|
||||
def isAlolaPokemon(species)
|
||||
dexNum = getDexNumberForSpecies(species)
|
||||
list = [
|
||||
370, 373, 430,431,432,433,450, 451,452,
|
||||
453,454,455, 459,460, 463, 464, 465
|
||||
]
|
||||
return list.include?(dexNum)
|
||||
end
|
||||
|
||||
def isKalosPokemon(species)
|
||||
dexNum = getDexNumberForSpecies(species)
|
||||
list =
|
||||
[327,328,329,339,371,372,417,418,
|
||||
425,426,438,439, 440,441,444,445,446,
|
||||
456,461,462
|
||||
]
|
||||
return list.include?(dexNum)
|
||||
end
|
||||
|
||||
def isUnovaPokemon(species)
|
||||
dexNum = getDexNumberForSpecies(species)
|
||||
list =
|
||||
[
|
||||
330,331,337,338,348,349,350,351,359,360,361,
|
||||
362,363,364,365,366,367,368,369,374,375,376,377,
|
||||
397,398,399,406,407,408,409,410,411,412,413,414,
|
||||
415,416,419,420,
|
||||
422,423,424,434,345
|
||||
]
|
||||
return list.include?(dexNum)
|
||||
end
|
||||
|
||||
def isSinnohPokemon(species)
|
||||
dexNum = getDexNumberForSpecies(species)
|
||||
list =
|
||||
@@ -417,7 +449,9 @@ def isSinnohPokemon(species)
|
||||
266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 288, 294,
|
||||
295, 296, 297, 298, 299, 305, 306, 307, 308, 315, 316, 317,
|
||||
318, 319, 320, 321, 322, 323, 324, 326, 332, 343, 344, 345,
|
||||
346, 347, 352, 353, 354, 358, 383, 384, 388, 389, 400, 402, 403]
|
||||
346, 347, 352, 353, 354, 358, 383, 384, 388, 389, 400, 402, 403,
|
||||
429
|
||||
]
|
||||
return list.include?(dexNum)
|
||||
end
|
||||
|
||||
@@ -427,7 +461,9 @@ def isHoennPokemon(species)
|
||||
285, 286, 287, 289, 290, 291, 292, 293, 300, 301, 302, 303,
|
||||
304, 309, 310, 311, 312, 313, 314, 333, 334, 335, 336, 340,
|
||||
341, 342, 355, 356, 357, 378, 379, 380, 381, 382, 385, 386, 387, 390,
|
||||
391, 392, 393, 394, 395, 396, 401, 404, 405]
|
||||
391, 392, 393, 394, 395, 396, 401, 404, 405,
|
||||
421, 427,428, 436,437,442,443,447,448,449, 457,458
|
||||
]
|
||||
return list.include?(dexNum)
|
||||
end
|
||||
|
||||
@@ -480,7 +516,6 @@ def customSpriteExistsForm(species,form_id_head=nil, form_id_body=nil)
|
||||
spritename += "_" + form_id_body.to_s if form_id_body
|
||||
|
||||
pathCustom = _INTL("Graphics/CustomBattlers/indexed/{1}/{2}.png", folder, spritename)
|
||||
|
||||
return true if pbResolveBitmap(pathCustom) != nil
|
||||
return download_custom_sprite(head, body,form_id_head,form_id_body) != nil
|
||||
end
|
||||
|
||||
@@ -56,7 +56,7 @@ def download_sprite(base_path, head_id, body_id, saveLocation = "Graphics/temp",
|
||||
|
||||
downloaded_file_name = _INTL("{1}/{2}.{3}{4}.png", saveLocation, head_id, body_id, alt_letter)
|
||||
if !body_id || body_id == ""
|
||||
downloaded_file_name = _INTL("{1}/{2}{3}.png", saveLocation, head_id, alt_letter)
|
||||
downloaded_file_name = _INTL("{1}{2}{3}.png", saveLocation, head_id, alt_letter)
|
||||
end
|
||||
|
||||
return downloaded_file_name if pbResolveBitmap(downloaded_file_name)
|
||||
@@ -75,17 +75,23 @@ def download_sprite(base_path, head_id, body_id, saveLocation = "Graphics/temp",
|
||||
echoln _INTL("\nDownloaded file from {1} to {2}", base_path, saveLocation)
|
||||
return downloaded_file_name
|
||||
end
|
||||
echoln "tried to download " + base_path
|
||||
return nil
|
||||
rescue MKXPError, Errno::ENOENT
|
||||
return nil
|
||||
end
|
||||
end
|
||||
|
||||
def download_autogen_sprite(head_id, body_id)
|
||||
def download_autogen_sprite(head_id, body_id,spriteformBody_suffix=nil,spriteformHead_suffix=nil)
|
||||
return nil if $PokemonSystem.download_sprites != 0
|
||||
url = Settings::AUTOGEN_SPRITES_REPO_URL + "{1}/{1}.{2}.png"
|
||||
template_url = Settings::AUTOGEN_SPRITES_REPO_URL + "{1}/{1}.{2}.png"
|
||||
|
||||
head_id = (head_id.to_s) + "_" + spriteformHead_suffix.to_s if spriteformHead_suffix
|
||||
body_id = (body_id.to_s) + "_" + spriteformBody_suffix.to_s if spriteformBody_suffix
|
||||
|
||||
destPath = _INTL("{1}{2}", Settings::BATTLERS_FOLDER, head_id)
|
||||
sprite = download_sprite(_INTL(url, head_id, body_id), head_id, body_id, destPath)
|
||||
url = _INTL(template_url, head_id, body_id)
|
||||
sprite = download_sprite(url, head_id, body_id, destPath)
|
||||
return sprite if sprite
|
||||
return nil
|
||||
end
|
||||
@@ -109,8 +115,6 @@ def download_unfused_main_sprite(dex_num, alt_letter="")
|
||||
base_url = alt_letter == "" ? Settings::BASE_POKEMON_SPRITES_REPO_URL : Settings::BASE_POKEMON_ALT_SPRITES_REPO_URL
|
||||
filename = _INTL("{1}{2}.png",dex_num,alt_letter)
|
||||
url = base_url + filename
|
||||
|
||||
|
||||
destPath = alt_letter == "" ? _INTL("{1}{2}", Settings::BATTLERS_FOLDER, dex_num) : Settings::CUSTOM_BASE_SPRITES_FOLDER
|
||||
sprite = download_sprite(url, dex_num, nil, destPath,alt_letter)
|
||||
|
||||
|
||||
@@ -333,7 +333,28 @@ class PokemonLoadScreen
|
||||
end
|
||||
end
|
||||
|
||||
def detectFakeDownload()
|
||||
blacklist = ["pokemoninfinitefusion.net"]
|
||||
current_user_directory=Dir.pwd
|
||||
for keyword in blacklist
|
||||
if current_user_directory.include?(keyword)
|
||||
pbMessage("The game has detected that it has been installed from an illegitimate source which likely contains viruses.")
|
||||
pbMessage("Please delete the game and reinstall it from the Discord or subreddit")
|
||||
pbMessage("discord.gg/infinitefusion\nreddit.com/r/pokemoninfinitefusion")
|
||||
|
||||
pbMessage("Please also make sure to report the website you originally downloaded the game from to Google.")
|
||||
return true
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
def fakeWebsiteDisclaimer()
|
||||
pbMessage("Reminder: This game does NOT have an official website. The ONLY official sources for the game are game's official discord or subreddit.")
|
||||
end
|
||||
|
||||
def pbStartLoadScreen
|
||||
return if detectFakeDownload
|
||||
fakeWebsiteDisclaimer()
|
||||
updateHttpSettingsFile
|
||||
updateCreditsFile
|
||||
newer_version = find_newer_available_version
|
||||
@@ -412,6 +433,7 @@ class PokemonLoadScreen
|
||||
Game.load(@save_data)
|
||||
$game_switches[SWITCH_V5_1] = true
|
||||
$PokemonGlobal.alt_sprite_substitutions = {} if !$PokemonGlobal.alt_sprite_substitutions
|
||||
$PokemonGlobal.autogen_sprites_cache = {}
|
||||
return
|
||||
when cmd_new_game
|
||||
@scene.pbEndScene
|
||||
|
||||
@@ -1471,6 +1471,11 @@ def pbFuse(pokemon, poke2, splicer_item)
|
||||
end
|
||||
|
||||
def pbUnfuse(pokemon, scene, supersplicers, pcPosition = nil)
|
||||
if pokemon.species_data.id_number > (NB_POKEMON * NB_POKEMON) + NB_POKEMON #triple fusion
|
||||
scene.pbDisplay(_INTL("{1} cannot be unfused.", pokemon.name))
|
||||
return false
|
||||
end
|
||||
|
||||
pokemon.spriteform_body=nil
|
||||
pokemon.spriteform_head=nil
|
||||
|
||||
@@ -1482,11 +1487,6 @@ def pbUnfuse(pokemon, scene, supersplicers, pcPosition = nil)
|
||||
return false
|
||||
else
|
||||
if Kernel.pbConfirmMessageSerious(_INTL("Should {1} be unfused?", pokemon.name))
|
||||
if pokemon.species_data.id_number > (NB_POKEMON * NB_POKEMON) + NB_POKEMON #triple fusion
|
||||
scene.pbDisplay(_INTL("{1} cannot be unfused.", pokemon.name))
|
||||
return false
|
||||
end
|
||||
|
||||
keepInParty = 0
|
||||
if $Trainer.party.length >= 6 && !pcPosition
|
||||
scene.pbDisplay(_INTL("Your party is full! Keep which Pokémon in party?"))
|
||||
|
||||
@@ -138,12 +138,12 @@ QUESTS = [
|
||||
Quest.new(37, "The Largest Carp", "A fisherman wants you to fish up a Magikarp that's exceptionally high-level at Dragon's Den.", questBranchHotels, "BW (71)", "Blackthorn City", defaultQuestColor),
|
||||
|
||||
#Ecruteak City
|
||||
Quest.new(38, "Kalos Pokémon", "A woman wants you to show her a Pokémon native to the Kalos region.", questBranchHotels, "BW (37)", "Ecruteak City", defaultQuestColor),
|
||||
Quest.new(38, "Kalos Pokémon", "A woman wants you to show her a Pokémon native to the Kalos region.", questBranchHotels, "BW (348)", "Ecruteak City", defaultQuestColor),
|
||||
Quest.new(39, "Ghost Evolution", "A girl in Ecruteak City wants you to show her a fully-evolved Ghost Pokémon.", questBranchHotels, "BW014", "Ecruteak City", defaultQuestColor),
|
||||
|
||||
#Kin Island
|
||||
Quest.new(40, "Banana Slamma!", "Collect 30 bananas", questBranchHotels, "BW029", "Kin Island", defaultQuestColor),
|
||||
Quest.new(41, "Unova Pokémon", "A woman wants you to show her a Pokémon native to the Unova region.", questBranchHotels, "BW (37)", "Kin Island", defaultQuestColor),
|
||||
Quest.new(40, "Banana Slamma!", "Collect 30 bananas", questBranchHotels, "BW059", "Kin Island", defaultQuestColor),
|
||||
Quest.new(41, "Unova Pokémon", "A woman wants you to show her a Pokémon native to the Unova region.", questBranchHotels, "BW (48)", "Kin Island", defaultQuestColor),
|
||||
Quest.new(42, "Stolen artifact", "Recover a stolen vase from a burglar in the Pokémon Mansion", questBranchHotels, "BW (21)", "Cinnabar Island", defaultQuestColor),
|
||||
Quest.new(43, "Fallen Meteor", "Investigate a crater near Bond Bridge.", questBranchHotels, "BW009", "Kin Island", defaultQuestColor),
|
||||
Quest.new(44, "First Contact", "Find the missing pieces of a fallen alien spaceship", questBranchHotels, "BW (92)", "Bond Bridge", questBranchField),
|
||||
|
||||
@@ -220,3 +220,37 @@ def format_names_for_game_credits()
|
||||
end
|
||||
return formatted
|
||||
end
|
||||
|
||||
def get_spritename_from_path(file_path,includeExtension=false)
|
||||
filename_with_extension = File.basename(file_path)
|
||||
filename_without_extension = File.basename(filename_with_extension, ".*")
|
||||
return filename_with_extension if includeExtension
|
||||
return filename_without_extension
|
||||
end
|
||||
|
||||
def getSpriterCreditForDexNumber(species_sym)
|
||||
#download sprite to make sure it's in the substitutions map
|
||||
body_id = getBodyID(species_sym)
|
||||
head_id = getHeadID(species_sym,body_id)
|
||||
|
||||
spritePath = get_fusion_sprite_path(head_id,body_id)
|
||||
spritename = get_spritename_from_path(spritePath)
|
||||
|
||||
return getSpriteCredits(spritename)
|
||||
end
|
||||
|
||||
|
||||
#
|
||||
# def getSpriterCreditForPokemon(species_sym)
|
||||
# p species_sym
|
||||
# #download sprite to make sure it's in the substitutions map
|
||||
# head_id = get_head_id_from_symbol(species_sym)
|
||||
# body_id = get_body_id_from_symbol(species_sym)
|
||||
#
|
||||
# echoln head_id
|
||||
# echoln body_id
|
||||
# spritename = get_fusion_sprite_path(head_id,body_id)
|
||||
# p spritename
|
||||
# p getSpriteCredits(spritename)
|
||||
# return getSpriteCredits(spritename)
|
||||
# end
|
||||
@@ -214,8 +214,7 @@ def getFusionSpeciesSymbol(body, head)
|
||||
nb_pokemon = Settings::NB_POKEMON
|
||||
id = body_num * nb_pokemon + head_num
|
||||
if id > (nb_pokemon*nb_pokemon)+nb_pokemon
|
||||
Kernel.pbMessage(_INTL("The randomizer has encountered an error. You should try to re-randomize your game as soon as possible."))
|
||||
Kernel.pbMessage(_INTL("You can do this on the top floor of Pokémon Centers."))
|
||||
displayRandomizerErrorMessage()
|
||||
return body
|
||||
end
|
||||
|
||||
|
||||
@@ -103,6 +103,7 @@ class PokemonPokedexInfo_Scene
|
||||
|
||||
def set_displayed_to_current_alt(altsList)
|
||||
species_id = getDexNumberForSpecies(@species).to_s
|
||||
$PokemonGlobal.alt_sprite_substitutions = {} if !$PokemonGlobal.alt_sprite_substitutions
|
||||
return if !$PokemonGlobal.alt_sprite_substitutions[species_id]
|
||||
|
||||
current_sprite =$PokemonGlobal.alt_sprite_substitutions[species_id]
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
RandTrainerNames_male = [
|
||||
"Mikaël",
|
||||
"James",
|
||||
@@ -1040,5 +1039,33 @@ RandPokeNick = [
|
||||
"Chewbacca",
|
||||
"Schrroms",
|
||||
"Boris",
|
||||
"maymay"
|
||||
"maymay",
|
||||
"Aegide",
|
||||
"Avian",
|
||||
"BB",
|
||||
"Blaquaza",
|
||||
"Coram",
|
||||
"Daena",
|
||||
"Cabine",
|
||||
"Gastly",
|
||||
"Gamr",
|
||||
"Hero",
|
||||
"Howls",
|
||||
"Ignus",
|
||||
"Katten",
|
||||
"Kuwu",
|
||||
"Milchik",
|
||||
"Maelmc",
|
||||
"Milian",
|
||||
"My Sins",
|
||||
"Naka",
|
||||
"Paya",
|
||||
"Pix",
|
||||
"Rose",
|
||||
"Tee",
|
||||
"Term",
|
||||
"Vince",
|
||||
"Thorns",
|
||||
"Xillo",
|
||||
"Froggywoggy"
|
||||
]
|
||||
|
||||
@@ -98,7 +98,7 @@ def pbWonderTrade(lvl, except = [], except2 = [], premiumWonderTrade = true)
|
||||
end
|
||||
if species > 0
|
||||
skipLegendaryCheck = premiumWonderTrade && rand(100) < luck
|
||||
species = 0 if pokemonIsPartLegendary(species) && !$game_switches[SWITCH_BEAT_THcE_LEAGUE] && !skipLegendaryCheck
|
||||
species = 0 if pokemonIsPartLegendary(species) && !$game_switches[SWITCH_BEAT_THE_LEAGUE] && !skipLegendaryCheck
|
||||
end
|
||||
#Redo loop if below BST - 200
|
||||
species = 0 if bst < (chosenBST - 200)
|
||||
@@ -116,7 +116,7 @@ def pbWonderTrade(lvl, except = [], except2 = [], premiumWonderTrade = true)
|
||||
end
|
||||
end
|
||||
randTrainerNames = RandTrainerNames_male + RandTrainerNames_female + RandTrainerNames_others
|
||||
tname = randTrainerNames[rand(randTrainerNames.size)] # Randomizes Trainer Names
|
||||
#tname = randTrainerNames[rand(randTrainerNames.size)] # Randomizes Trainer Names
|
||||
pname = RandPokeNick[rand(RandPokeNick.size)] # Randomizes Pokemon Nicknames
|
||||
|
||||
#num of Wondertrade - 1
|
||||
@@ -125,7 +125,8 @@ def pbWonderTrade(lvl, except = [], except2 = [], premiumWonderTrade = true)
|
||||
else
|
||||
$game_variables[VAR_STANDARD_WONDERTRADE_LEFT] -= 1
|
||||
end
|
||||
|
||||
tname = getSpriterCreditForDexNumber(species)
|
||||
tname = randTrainerNames[rand(randTrainerNames.size)] if ! tname
|
||||
newpoke = pbStartTrade(pbGet(1), species, pname, tname, 0, true) # Starts the trade
|
||||
#lower level by 1 to prevent abuse
|
||||
if poke.level > 25
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
|
||||
EXPORT_EXCEPT_MAP_IDS= [768,722,723,724,720]
|
||||
EXPORT_EXCEPT_MAP_IDS= [768,722,723,724,720,809,816]
|
||||
|
||||
def exportAllMaps
|
||||
for id in 810..815
|
||||
for id in 817..830
|
||||
begin
|
||||
MapExporter.export(id, [:Events]) if !EXPORT_EXCEPT_MAP_IDS.include?(id)
|
||||
rescue
|
||||
|
||||
@@ -43,6 +43,8 @@ def handleReplaceExistingSprites()
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
|
||||
def pbCallTitle
|
||||
#return Scene_DebugIntro.new if $DEBUG
|
||||
return Scene_Intro.new
|
||||
@@ -75,14 +77,16 @@ def sortCustomBattlers()
|
||||
next if !filename.end_with?(".png")
|
||||
headNum = filename.split('.')[0]
|
||||
oldPath = Settings::CUSTOM_BATTLERS_FOLDER + filename
|
||||
newPath = Settings::CUSTOM_BATTLERS_FOLDER_INDEXED + headNum.to_s + "/" + filename
|
||||
newDir = Settings::CUSTOM_BATTLERS_FOLDER_INDEXED + headNum.to_s
|
||||
newPath = newDir + "/" + filename
|
||||
begin
|
||||
if File.file?(newPath)
|
||||
alreadyExists[oldPath] = newPath
|
||||
echo "\nFile " + newPath + " already exists... Skipping."
|
||||
|
||||
else
|
||||
File.rename(oldPath, newPath)
|
||||
Dir.mkdir(newDir) if !Dir.exist?(newDir)
|
||||
File.rename(oldPath, newPath)
|
||||
$game_temp.nb_imported_sprites+=1
|
||||
echo "\nSorted " + filename + " into " + newPath
|
||||
end
|
||||
|
||||
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 4.2 KiB |
BIN
Graphics/Characters/players/boy_surf_offset1.png
Normal file
|
After Width: | Height: | Size: 9.1 KiB |
BIN
Graphics/Characters/silhouette.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
Graphics/Characters/trchar_pokeflute.png
Normal file
|
After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 832 B |
|
Before Width: | Height: | Size: 286 B |
|
Before Width: | Height: | Size: 286 B |
|
Before Width: | Height: | Size: 826 B |
|
Before Width: | Height: | Size: 6.3 KiB After Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 54 KiB After Width: | Height: | Size: 54 KiB |
|
Before Width: | Height: | Size: 54 KiB |