From 3a135f8cbbca1fe52a76bb971bded52ad1e2dac4 Mon Sep 17 00:00:00 2001 From: Derek Hoffmann Date: Thu, 29 Feb 2024 17:31:53 -0500 Subject: [PATCH] [almanac.lic] check almanac is defined in gear --- almanac.lic | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/almanac.lic b/almanac.lic index 3a58c56a41..8cc74daf13 100644 --- a/almanac.lic +++ b/almanac.lic @@ -16,6 +16,16 @@ class Almanac startup_delay = settings.almanac_startup_delay + # check to ensure almanac is defined in gear, and warn user if not + if settings.gear.find { |item| @almanac =~ /#{item[:adjective]}\s*#{item[:name]}/i }.nil? + message = "To minimize the possibility that items that you hold in your hands could be lost they should be listed in your `gear:`. Your almanac is not listed in your `gear:` settings:" + message += "\n - #{@almanac}" + message += "\nIf you need assistance with this, please ask in the lich discord (listed in #{$clean_lich_char}links) for help." + message += "\n\n---This check is *advisory* for now, but will become mandatory in the near future.---" + DRC.message(message) + pause 10 + end + pause startup_delay passive_loop end