From 59de794e58023edeaf218b739bb578fe80cd8150 Mon Sep 17 00:00:00 2001 From: Marek Kochanowicz Date: Mon, 13 Jan 2014 19:02:23 +0100 Subject: [PATCH] Creature check was not invoked. --- apps/opencs/model/tools/referenceablecheck.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/apps/opencs/model/tools/referenceablecheck.cpp b/apps/opencs/model/tools/referenceablecheck.cpp index d5064d272..f89c641d4 100644 --- a/apps/opencs/model/tools/referenceablecheck.cpp +++ b/apps/opencs/model/tools/referenceablecheck.cpp @@ -206,7 +206,16 @@ void CSMTools::ReferenceableCheckStage::perform(int stage, std::vector< std::str staticCheck(stage, mReferencables.getStatics(), messages); return; } + + stage -= staticSize; + const int creatureSize(mReferencables.getCreatures().getSize()); + + if (stage < creatureSize) + { + creatureCheck(stage, mReferencables.getCreatures(), messages); + return; + } // if we come that far, we are about to perform our last, final check. finalCheck(messages); return; @@ -215,7 +224,7 @@ void CSMTools::ReferenceableCheckStage::perform(int stage, std::vector< std::str int CSMTools::ReferenceableCheckStage::setup() { mPlayerPresent = false; - return mReferencables.getSize() + 2; //DANGER, final check is not performed if it is just +1 + return mReferencables.getSize() + 1; } void CSMTools::ReferenceableCheckStage::bookCheck(