mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-08 21:54:58 +00:00
pokemon preview window + bugfixes
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -24,8 +24,6 @@ class Scene_Map
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class Scene_Battle
|
class Scene_Battle
|
||||||
def updatemini
|
def updatemini
|
||||||
if self.respond_to?("update_basic")
|
if self.respond_to?("update_basic")
|
||||||
@@ -59,8 +57,6 @@ class Scene_Battle
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def pbMapInterpreter
|
def pbMapInterpreter
|
||||||
if $game_map.respond_to?("interpreter")
|
if $game_map.respond_to?("interpreter")
|
||||||
return $game_map.interpreter
|
return $game_map.interpreter
|
||||||
@@ -131,8 +127,6 @@ def pbCurrentEventCommentInput(elements,trigger)
|
|||||||
return pbEventCommentInput(event, elements, trigger)
|
return pbEventCommentInput(event, elements, trigger)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
#
|
#
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
@@ -251,8 +245,6 @@ class ChooseNumberParams
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def pbChooseNumber(msgwindow, params)
|
def pbChooseNumber(msgwindow, params)
|
||||||
return 0 if !params
|
return 0 if !params
|
||||||
ret = 0
|
ret = 0
|
||||||
@@ -295,8 +287,6 @@ def pbChooseNumber(msgwindow,params)
|
|||||||
return ret
|
return ret
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
#
|
#
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
@@ -335,8 +325,6 @@ class FaceWindowVX < SpriteWindow_Base
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
#
|
#
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
@@ -399,8 +387,6 @@ def pbCsvPosInt!(str)
|
|||||||
return ret.to_i
|
return ret.to_i
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
# Money and coins windows
|
# Money and coins windows
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
@@ -498,8 +484,6 @@ def pbDisplayBattlePointsWindow(msgwindow)
|
|||||||
return pointswindow
|
return pointswindow
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
#
|
#
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
@@ -540,8 +524,6 @@ def pbDisposeMessageWindow(msgwindow)
|
|||||||
msgwindow.dispose
|
msgwindow.dispose
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
# Main message-displaying function
|
# Main message-displaying function
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
@@ -719,8 +701,12 @@ def pbMessageDisplay(msgwindow,message,letterbyletter=true,commandProc=nil)
|
|||||||
param = controls[i][1]
|
param = controls[i][1]
|
||||||
case control
|
case control
|
||||||
when "f"
|
when "f"
|
||||||
|
isFusion = param.to_i > NB_POKEMON
|
||||||
|
head = getBasePokemonID(param.to_i, false)
|
||||||
|
body = getBasePokemonID(param.to_i, true)
|
||||||
facewindow.dispose if facewindow
|
facewindow.dispose if facewindow
|
||||||
facewindow = PictureWindow.new("Graphics/Pictures/#{param}")
|
path = obtainPokemonSpritePath(body, head, $game_variables[CUSTOM_SPRITES_ENABLED] == 0)
|
||||||
|
facewindow = isFusion ? PictureWindow.new(path) : PictureWindow.new("Graphics/Battlers/#{head}/#{head}.png")
|
||||||
pbPositionNearMsgWindow(facewindow, msgwindow, :left)
|
pbPositionNearMsgWindow(facewindow, msgwindow, :left)
|
||||||
facewindow.viewport = msgwindow.viewport
|
facewindow.viewport = msgwindow.viewport
|
||||||
facewindow.z = msgwindow.z
|
facewindow.z = msgwindow.z
|
||||||
@@ -837,8 +823,6 @@ def pbMessageDisplay(msgwindow,message,letterbyletter=true,commandProc=nil)
|
|||||||
return ret
|
return ret
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
# Message-displaying functions
|
# Message-displaying functions
|
||||||
#===============================================================================
|
#===============================================================================
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ def pbAddToPartySilent(pkmn, level = nil, see_form = true)
|
|||||||
end
|
end
|
||||||
|
|
||||||
def pbAddForeignPokemon(pkmn, level = 1, owner_name = nil, nickname = nil, owner_gender = 0, see_form = true)
|
def pbAddForeignPokemon(pkmn, level = 1, owner_name = nil, nickname = nil, owner_gender = 0, see_form = true)
|
||||||
return false if !pkmn || $Trainer.party_full?
|
return false if !pkmn
|
||||||
pkmn = Pokemon.new(pkmn, level) if !pkmn.is_a?(Pokemon)
|
pkmn = Pokemon.new(pkmn, level) if !pkmn.is_a?(Pokemon)
|
||||||
# Set original trainer to a foreign one
|
# Set original trainer to a foreign one
|
||||||
pkmn.owner = Pokemon::Owner.new_foreign(owner_name || "", owner_gender)
|
pkmn.owner = Pokemon::Owner.new_foreign(owner_name || "", owner_gender)
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ GOT_BADGE_16 = 50
|
|||||||
DEFAULT_BATTLE_TYPE = 242
|
DEFAULT_BATTLE_TYPE = 242
|
||||||
BATTLE_FACTORY_TOKENS = 243
|
BATTLE_FACTORY_TOKENS = 243
|
||||||
NB_GYM_REMATCHES = 162
|
NB_GYM_REMATCHES = 162
|
||||||
|
CUSTOM_SPRITES_ENABLED= 196
|
||||||
#Settings
|
#Settings
|
||||||
# This is for settings that are used in scripts since it's a chore to change them everywhere to include the module name
|
# This is for settings that are used in scripts since it's a chore to change them everywhere to include the module name
|
||||||
NUM_BADGES = Settings::NB_BADGES
|
NUM_BADGES = Settings::NB_BADGES
|
||||||
|
|||||||
@@ -298,3 +298,25 @@ def getGenericPokemonCryText(pokemonSpecies)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def obtainPokemonSpritePath(id,includeCustoms=true)
|
||||||
|
head=getBasePokemonID(param.to_i,false)
|
||||||
|
body=getBasePokemonID(param.to_i,true)
|
||||||
|
return obtainPokemonSpritePath(body,head,includeCustoms)
|
||||||
|
end
|
||||||
|
|
||||||
|
def obtainPokemonSpritePath(bodyId, headId,include_customs=true)
|
||||||
|
hasCustom=false
|
||||||
|
picturePath = _INTL("Graphics/Battlers/{1}/{1}.{2}.png", headId, bodyId)
|
||||||
|
|
||||||
|
if include_customs
|
||||||
|
pathCustom = _INTL("Graphics/CustomBattlers/{1}.{2}.png", headId, bodyId)
|
||||||
|
if (pbResolveBitmap(pathCustom))
|
||||||
|
picturePath = pathCustom
|
||||||
|
hasCustom = true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return picturePath
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -134,6 +134,7 @@ def evolveRematchPokemon(nbRematch, speciesSymbol)
|
|||||||
end
|
end
|
||||||
|
|
||||||
def getEvolution(species)
|
def getEvolution(species)
|
||||||
|
begin
|
||||||
if species >= Settings::NB_POKEMON
|
if species >= Settings::NB_POKEMON
|
||||||
body = getBasePokemonID(species)
|
body = getBasePokemonID(species)
|
||||||
head = getBasePokemonID(species, false)
|
head = getBasePokemonID(species, false)
|
||||||
@@ -162,6 +163,9 @@ def getEvolution(species)
|
|||||||
newSpecies = evo[rand(evo.length - 1)][0]
|
newSpecies = evo[rand(evo.length - 1)][0]
|
||||||
return evo.any? ? getDexNumberForSpecies(newSpecies) : -1
|
return evo.any? ? getDexNumberForSpecies(newSpecies) : -1
|
||||||
end
|
end
|
||||||
|
rescue
|
||||||
|
return -1
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def getFusionSpecies(body, head)
|
def getFusionSpecies(body, head)
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user