1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-12-05 09:34:31 +00:00

CLEANUP: Update for MR Comments

This commit is contained in:
Dave Corley 2025-07-10 17:25:30 -07:00
parent 8ec4fcbf30
commit 943cd765e7

View file

@ -1,13 +1,12 @@
#include "types.hpp" #include "types.hpp"
#include <apps/openmw/mwbase/dialoguemanager.hpp>
#include <components/esm3/loadbsgn.hpp> #include <components/esm3/loadbsgn.hpp>
#include <components/esm3/loadfact.hpp> #include <components/esm3/loadfact.hpp>
#include <components/misc/strings/format.hpp>
#include "../birthsignbindings.hpp" #include "../birthsignbindings.hpp"
#include "../luamanagerimp.hpp" #include "../luamanagerimp.hpp"
#include "apps/openmw/mwbase/dialoguemanager.hpp"
#include "apps/openmw/mwbase/inputmanager.hpp" #include "apps/openmw/mwbase/inputmanager.hpp"
#include "apps/openmw/mwbase/journal.hpp" #include "apps/openmw/mwbase/journal.hpp"
#include "apps/openmw/mwbase/mechanicsmanager.hpp" #include "apps/openmw/mwbase/mechanicsmanager.hpp"
@ -205,11 +204,10 @@ namespace MWLua
= MWBase::Environment::get().getESMStore()->get<ESM::Dialogue>().search(topic); = MWBase::Environment::get().getESMStore()->get<ESM::Dialogue>().search(topic);
if (!dialogueRecord) if (!dialogueRecord)
throw std::runtime_error( throw std::runtime_error("Failed to add topic " + std::string(topicId) + ": topic record not found");
Misc::StringUtils::format("Failed to add topic ", topicId, ": topic record not found"));
else if (dialogueRecord->mType != ESM::Dialogue::Topic) if (dialogueRecord->mType != ESM::Dialogue::Topic)
throw std::runtime_error( throw std::runtime_error("Failed to add topic " + std::string(topicId) + ": record is not a topic");
Misc::StringUtils::format("Failed to add topic ", topicId, ": record is not a topic"));
MWBase::Environment::get().getDialogueManager()->addTopic(topic); MWBase::Environment::get().getDialogueManager()->addTopic(topic);
}; };