From 4b98850c3ad0cbd0c8f08c150da3cdc85715c75f Mon Sep 17 00:00:00 2001 From: Maruno17 Date: Sat, 10 Jul 2021 19:23:56 +0100 Subject: [PATCH] =?UTF-8?q?Stopped=20U-turn=20switching=20if=20the=20battl?= =?UTF-8?q?e=20is=20over,=20ensured=20animation=20spritesheet=20file=20ext?= =?UTF-8?q?ensions=20are=20removed=20from=20animation=20data,=20added=20De?= =?UTF-8?q?bug=20function=20to=20reload=20system=20cache,=20Pok=C3=A9mon?= =?UTF-8?q?=20debug=20menu=20now=20shows=20the=20Pok=C3=A9mon's=20status?= =?UTF-8?q?=20problem,=20changed=20mkxp.json=20to=20fix=20uncommon=20rende?= =?UTF-8?q?ring=20problems?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../011_Battle/002_Move/006_Move_Effects_080-0FF.rb | 2 +- .../002_Animation editor/005_AnimEditor_Functions.rb | 5 +++-- .../003_Debug menus/002_Debug_MenuCommands.rb | 11 +++++++++++ .../003_Debug menus/005_Debug_PokemonCommands.rb | 10 +++++++--- mkxp.json | 4 ++-- 5 files changed, 24 insertions(+), 8 deletions(-) diff --git a/Data/Scripts/011_Battle/002_Move/006_Move_Effects_080-0FF.rb b/Data/Scripts/011_Battle/002_Move/006_Move_Effects_080-0FF.rb index 8d46afd17..f54e789dd 100644 --- a/Data/Scripts/011_Battle/002_Move/006_Move_Effects_080-0FF.rb +++ b/Data/Scripts/011_Battle/002_Move/006_Move_Effects_080-0FF.rb @@ -3157,7 +3157,7 @@ end #=============================================================================== class PokeBattle_Move_0EE < PokeBattle_Move def pbEndOfMoveUsageEffect(user,targets,numHits,switchedBattlers) - return if user.fainted? || numHits==0 + return if user.fainted? || numHits==0 || @battle.pbAllFainted?(user.idxOpposingSide) targetSwitched = true targets.each do |b| targetSwitched = false if !switchedBattlers.include?(b.index) diff --git a/Data/Scripts/020_Debug/002_Animation editor/005_AnimEditor_Functions.rb b/Data/Scripts/020_Debug/002_Animation editor/005_AnimEditor_Functions.rb index 940303f0c..ae78a290a 100644 --- a/Data/Scripts/020_Debug/002_Animation editor/005_AnimEditor_Functions.rb +++ b/Data/Scripts/020_Debug/002_Animation editor/005_AnimEditor_Functions.rb @@ -47,8 +47,9 @@ def pbSelectAnim(canvas,animwin) ctlwin.update bmpwin.hue=ctlwin.value(0) if ctlwin.changed?(0) if Input.trigger?(Input::USE) && animfiles.length>0 - bitmap=AnimatedBitmap.new("Graphics/Animations/"+cmdwin.commands[cmdwin.index],ctlwin.value(0)).deanimate - canvas.animation.graphic=cmdwin.commands[cmdwin.index] + filename = 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.animbitmap=bitmap animwin.animbitmap=bitmap diff --git a/Data/Scripts/020_Debug/003_Debug menus/002_Debug_MenuCommands.rb b/Data/Scripts/020_Debug/003_Debug menus/002_Debug_MenuCommands.rb index cbda679f0..c4ac90714 100644 --- a/Data/Scripts/020_Debug/003_Debug menus/002_Debug_MenuCommands.rb +++ b/Data/Scripts/020_Debug/003_Debug menus/002_Debug_MenuCommands.rb @@ -1153,3 +1153,14 @@ DebugMenuCommands.register("invalidtiles", { 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.")) + } +}) diff --git a/Data/Scripts/020_Debug/003_Debug menus/005_Debug_PokemonCommands.rb b/Data/Scripts/020_Debug/003_Debug menus/005_Debug_PokemonCommands.rb index 3d3300d2c..ddfe195e4 100644 --- a/Data/Scripts/020_Debug/003_Debug menus/005_Debug_PokemonCommands.rb +++ b/Data/Scripts/020_Debug/003_Debug menus/005_Debug_PokemonCommands.rb @@ -83,16 +83,20 @@ PokemonDebugMenuCommands.register("setstatus", { ids = [:NONE] GameData::Status.each do |s| next if s.id == :NONE - commands.push(s.name) + commands.push(_INTL("Set {1}", s.name)) ids.push(s.id) end 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 case cmd when 0 # Cure pkmn.heal_status - screen.pbDisplay(_INTL("{1}'s status was cured.", pkmn.name)) screen.pbRefreshSingle(pkmnid) else # Give status problem count = 0 diff --git a/mkxp.json b/mkxp.json index c0d1ae156..a44f4c1ad 100644 --- a/mkxp.json +++ b/mkxp.json @@ -132,7 +132,7 @@ // tileset doesn't render at all // (default: disabled) // - // "subImageFix": false, + "subImageFix": true, // Enable framebuffer blitting if the driver is @@ -141,7 +141,7 @@ // disabling it can be used as a workaround // (default: enabled) // - // "enableBlitting": true, + "enableBlitting": false, // Limit the maximum size (width, height) of