From dad1342cab0b1797c153c2dd0a7f3cb0c5e61751 Mon Sep 17 00:00:00 2001 From: Nat Quayle Nelson Date: Sun, 2 Mar 2025 18:06:22 -0600 Subject: [PATCH] eating don't trigger autosave while resting --- src/game/boe.actions.cpp | 6 +++--- src/game/boe.actions.hpp | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/game/boe.actions.cpp b/src/game/boe.actions.cpp index 12bb2aa4..c9b91dac 100644 --- a/src/game/boe.actions.cpp +++ b/src/game/boe.actions.cpp @@ -465,7 +465,7 @@ void handle_rest(bool& need_redraw, bool& need_reprint) { pause(25); univ.party.food -= 6; while(i < 50) { - increase_age(); + increase_age(false); if(get_ran(1,1,2) == 2) do_monsters(); if(get_ran(1,1,70) == 10) @@ -3072,7 +3072,7 @@ void do_rest(long length, int hp_restore, int mp_restore) { adjust_spell_menus(); } -void increase_age() { +void increase_age(bool eating_trigger_autosave) { short how_many_short = 0,r1; @@ -3200,7 +3200,7 @@ void increase_age() { else { play_sound(6); add_string_to_buf("You eat."); - try_auto_save("Eat"); + if(eating_trigger_autosave) try_auto_save("Eat"); } } diff --git a/src/game/boe.actions.hpp b/src/game/boe.actions.hpp index de4ce1f8..a994ecf9 100644 --- a/src/game/boe.actions.hpp +++ b/src/game/boe.actions.hpp @@ -29,7 +29,7 @@ void do_load(); void post_load(); void do_save(bool save_as = false); void do_abort(); -void increase_age(); +void increase_age(bool eating_trigger_autosave = true); void handle_hunting(); void switch_pc(short which); void handle_drop_pc();