From 610dc0169e9e94504eef0f24a5cc05534cfcb2dd Mon Sep 17 00:00:00 2001 From: michael Date: Sun, 4 Oct 2026 10:05:19 -0400 Subject: [PATCH] feat: debug-on reminder now also fires once per mission at gameplay start when Debug Mode was already ON at load (deferred from state-enter so the chat message is actually visible; silent when debug off or mod disabled) --- AutoMark/scripts/mods/AutoMark/AutoMark.lua | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/AutoMark/scripts/mods/AutoMark/AutoMark.lua b/AutoMark/scripts/mods/AutoMark/AutoMark.lua index d2f2f56..be94b13 100644 --- a/AutoMark/scripts/mods/AutoMark/AutoMark.lua +++ b/AutoMark/scripts/mods/AutoMark/AutoMark.lua @@ -359,6 +359,7 @@ mod.on_game_state_changed = function(status, state_name) if state_name == "GameplayStateRun" then if status == "enter" then mod:check_game_mode() + mod.debug_warn_pending = true -- game settings cache mod:init_game_settings() -- display @@ -716,6 +717,12 @@ mod:hook_safe(CLASS.PlayerUnitSmartTargetingExtension, "fixed_update", local game_mode_manager = Managers.state.game_mode mod:diag(string.format("OMNI-GATES class=%s companion=%s skull=%s mode=%s valid=%s toggle=%s debug=%s", tostring(context.class_name), tostring(context.has_companion), tostring(context.has_servo_skull), game_mode_manager and tostring(game_mode_manager:game_mode_name()) or "nil", tostring(context.game_mode_valid), tostring(mod_settings.toggle_mod), tostring(mod_settings.debug_mode))) end + if mod.debug_warn_pending and context.game_mode_valid then + mod.debug_warn_pending = false + if mod_settings.toggle_mod and mod_settings.debug_mode then + mod:notify("AutoMark DEBUG MODE is ON: file diagnostics in mods/AutoMark/diag_log.txt keep growing - turn it off when you are done!") + end + end if mod_settings.toggle_mod and context.game_mode_valid then mod.num_visibility_checks_this_frame = 0 clean_expired_units(t)