From a25c7bb2c07cbf00cb12e0dc8082947c4d1a9d0a Mon Sep 17 00:00:00 2001 From: Marc Zinnschlag Date: Sun, 8 Aug 2010 11:37:59 +0200 Subject: [PATCH] added test for cell name --- apps/openmw/mwdialogue/dialoguemanager.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/apps/openmw/mwdialogue/dialoguemanager.cpp b/apps/openmw/mwdialogue/dialoguemanager.cpp index c11e2bb0d8..941c760e77 100644 --- a/apps/openmw/mwdialogue/dialoguemanager.cpp +++ b/apps/openmw/mwdialogue/dialoguemanager.cpp @@ -21,7 +21,12 @@ namespace MWDialogue // TODO check actor class // TODO check actor faction // TODO check player faction - // TODO check cell + + // check cell + if (!info.cell.empty()) + if (mEnvironment.mWorld->getPlayerPos().getPlayer().getCell()->cell->name != info.cell) + return false; + // TODO check DATAstruct // TODO check select structures @@ -32,7 +37,6 @@ namespace MWDialogue << " actor class: " << info.clas << std::endl << " actor faction: " << info.npcFaction << std::endl << " player faction: " << info.pcFaction << std::endl - << " cell: " << info.cell << std::endl << " DATAstruct" << std::endl; for (std::vector::const_iterator iter (info.selects.begin());