Merge branch 'dev' into dev-gen8

This commit is contained in:
Maruno17
2021-07-10 19:49:08 +01:00
5 changed files with 24 additions and 8 deletions

View File

@@ -3157,7 +3157,7 @@ end
#=============================================================================== #===============================================================================
class PokeBattle_Move_0EE < PokeBattle_Move class PokeBattle_Move_0EE < PokeBattle_Move
def pbEndOfMoveUsageEffect(user,targets,numHits,switchedBattlers) def pbEndOfMoveUsageEffect(user,targets,numHits,switchedBattlers)
return if user.fainted? || numHits==0 return if user.fainted? || numHits==0 || @battle.pbAllFainted?(user.idxOpposingSide)
targetSwitched = true targetSwitched = true
targets.each do |b| targets.each do |b|
targetSwitched = false if !switchedBattlers.include?(b.index) targetSwitched = false if !switchedBattlers.include?(b.index)

View File

@@ -47,8 +47,9 @@ def pbSelectAnim(canvas,animwin)
ctlwin.update ctlwin.update
bmpwin.hue=ctlwin.value(0) if ctlwin.changed?(0) bmpwin.hue=ctlwin.value(0) if ctlwin.changed?(0)
if Input.trigger?(Input::USE) && animfiles.length>0 if Input.trigger?(Input::USE) && animfiles.length>0
bitmap=AnimatedBitmap.new("Graphics/Animations/"+cmdwin.commands[cmdwin.index],ctlwin.value(0)).deanimate filename = cmdwin.commands[cmdwin.index]
canvas.animation.graphic=cmdwin.commands[cmdwin.index] bitmap=AnimatedBitmap.new("Graphics/Animations/" + filename, ctlwin.value(0)).deanimate
canvas.animation.graphic = File.basename(filename, ".png")
canvas.animation.hue=ctlwin.value(0) canvas.animation.hue=ctlwin.value(0)
canvas.animbitmap=bitmap canvas.animbitmap=bitmap
animwin.animbitmap=bitmap animwin.animbitmap=bitmap

View File

@@ -1153,3 +1153,14 @@ DebugMenuCommands.register("invalidtiles", {
pbDebugFixInvalidTiles pbDebugFixInvalidTiles
} }
}) })
DebugMenuCommands.register("reloadsystemcache", {
"parent" => "othermenu",
"name" => _INTL("Reload System Cache"),
"description" => _INTL("Refreshes the system's file cache. Use if you change a file while playing."),
"always_show" => true,
"effect" => proc {
System.reload_cache
pbMessage(_INTL("Done."))
}
})

View File

@@ -83,16 +83,20 @@ PokemonDebugMenuCommands.register("setstatus", {
ids = [:NONE] ids = [:NONE]
GameData::Status.each do |s| GameData::Status.each do |s|
next if s.id == :NONE next if s.id == :NONE
commands.push(s.name) commands.push(_INTL("Set {1}", s.name))
ids.push(s.id) ids.push(s.id)
end end
loop do loop do
cmd = screen.pbShowCommands(_INTL("Set {1}'s status.", pkmn.name), commands, cmd) msg = _INTL("Current status: {1}", GameData::Status.get(pkmn.status).name)
if pkmn.status == :SLEEP
msg = _INTL("Current status: {1} (turns: {2})",
GameData::Status.get(pkmn.status).name, pkmn.statusCount)
end
cmd = screen.pbShowCommands(msg, commands, cmd)
break if cmd < 0 break if cmd < 0
case cmd case cmd
when 0 # Cure when 0 # Cure
pkmn.heal_status pkmn.heal_status
screen.pbDisplay(_INTL("{1}'s status was cured.", pkmn.name))
screen.pbRefreshSingle(pkmnid) screen.pbRefreshSingle(pkmnid)
else # Give status problem else # Give status problem
count = 0 count = 0

View File

@@ -132,7 +132,7 @@
// tileset doesn't render at all // tileset doesn't render at all
// (default: disabled) // (default: disabled)
// //
// "subImageFix": false, "subImageFix": true,
// Enable framebuffer blitting if the driver is // Enable framebuffer blitting if the driver is
@@ -141,7 +141,7 @@
// disabling it can be used as a workaround // disabling it can be used as a workaround
// (default: enabled) // (default: enabled)
// //
// "enableBlitting": true, "enableBlitting": false,
// Limit the maximum size (width, height) of // Limit the maximum size (width, height) of