From a87a9b3532b1d00f56b07a5a99a90a70df6b46f1 Mon Sep 17 00:00:00 2001 From: Kinglykrab Date: Mon, 10 Oct 2022 19:35:16 -0400 Subject: [PATCH] Remove unnecessary quest manager stuff. --- zone/embparser_api.cpp | 12 ++++++++++-- zone/questmgr.cpp | 16 ---------------- zone/questmgr.h | 2 -- 3 files changed, 10 insertions(+), 20 deletions(-) diff --git a/zone/embparser_api.cpp b/zone/embparser_api.cpp index d0dbafa4f..2e80e0c97 100644 --- a/zone/embparser_api.cpp +++ b/zone/embparser_api.cpp @@ -3708,12 +3708,20 @@ bool Perl__hasrecipelearned(uint32 recipe_id) bool Perl__IsRaining() { - return quest_manager.IsRaining(); + if (!zone) { + return false; + } + + return zone->IsRaining(); } bool Perl__IsSnowing() { - return quest_manager.IsSnowing(); + if (!zone) { + return false; + } + + return zone->IsSnowing(); } void perl_register_quest() diff --git a/zone/questmgr.cpp b/zone/questmgr.cpp index 6a92b025f..e72c527ef 100644 --- a/zone/questmgr.cpp +++ b/zone/questmgr.cpp @@ -3723,19 +3723,3 @@ void QuestManager::LearnRecipe(uint32 recipe_id) { initiator->LearnRecipe(recipe_id); } - -bool QuestManager::IsRaining() { - if (!zone) { - return false; - } - - return zone->IsRaining(); -} - -bool QuestManager::IsSnowing() { - if (!zone) { - return false; - } - - return zone->IsSnowing(); -} diff --git a/zone/questmgr.h b/zone/questmgr.h index 8069535d1..17e94f171 100644 --- a/zone/questmgr.h +++ b/zone/questmgr.h @@ -340,8 +340,6 @@ public: int GetRecipeMadeCount(uint32 recipe_id); std::string GetRecipeName(uint32 recipe_id); bool HasRecipeLearned(uint32 recipe_id); - bool IsRaining(); - bool IsSnowing(); Client *GetInitiator() const; NPC *GetNPC() const;