ajustos de qualitat, canvi de tecles, persistencia de opcions, etc
This commit is contained in:
@@ -9,6 +9,9 @@
|
||||
#include "core/locale/locale.hpp" // Para Locale
|
||||
#include "core/rendering/render_info.hpp" // Para RenderInfo
|
||||
#include "core/rendering/screen.hpp" // Para Screen
|
||||
#ifdef _DEBUG
|
||||
#include "core/system/debug.hpp" // Para Debug (persistencia de render_info en debug.yaml)
|
||||
#endif
|
||||
#include "game/options.hpp" // Para Options, options, OptionsVideo, Section
|
||||
#include "game/scene_manager.hpp" // Para SceneManager
|
||||
#include "game/ui/console.hpp" // Para Console
|
||||
@@ -292,7 +295,16 @@ namespace GlobalInputs {
|
||||
break;
|
||||
|
||||
case InputAction::TOGGLE_INFO:
|
||||
if (RenderInfo::get() != nullptr) { RenderInfo::get()->toggle(); }
|
||||
if (RenderInfo::get() != nullptr) {
|
||||
// Leemos la intención antes del toggle: isActive() incluye la
|
||||
// animación VANISHING, así que justo después de un toggle ACTIVE→OFF
|
||||
// seguiría devolviendo true y la persistencia no detectaría el cambio.
|
||||
const bool WAS_ACTIVE = RenderInfo::get()->isActive();
|
||||
RenderInfo::get()->toggle();
|
||||
#ifdef _DEBUG
|
||||
if (Debug::get() != nullptr) { Debug::get()->setRenderInfoEnabled(!WAS_ACTIVE); }
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
|
||||
case InputAction::NONE:
|
||||
|
||||
Reference in New Issue
Block a user