forked from mirror/openmw-tes3mp
removed redundant data from quest class
This commit is contained in:
parent
944291d34f
commit
3406d2fa89
2 changed files with 11 additions and 4 deletions
|
@ -78,10 +78,10 @@ namespace MWDialogue
|
|||
setIndex (index, world);
|
||||
|
||||
for (TEntryIter iter (mEntries.begin()); iter!=mEntries.end(); ++iter)
|
||||
if (iter->mInfoId==entry.mInfoId)
|
||||
if (*iter==entry.mInfoId)
|
||||
return;
|
||||
|
||||
mEntries.push_back (entry);
|
||||
mEntries.push_back (entry.mInfoId);
|
||||
}
|
||||
|
||||
Quest::TEntryIter Quest::begin()
|
||||
|
@ -93,4 +93,9 @@ namespace MWDialogue
|
|||
{
|
||||
return mEntries.end();
|
||||
}
|
||||
|
||||
JournalEntry Quest::getEntry (const std::string& infoId)
|
||||
{
|
||||
return JournalEntry (mTopic, infoId);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,14 +18,14 @@ namespace MWDialogue
|
|||
{
|
||||
public:
|
||||
|
||||
typedef std::vector<JournalEntry> TEntryContainer;
|
||||
typedef std::vector<std::string> TEntryContainer;
|
||||
typedef TEntryContainer::const_iterator TEntryIter;
|
||||
|
||||
private:
|
||||
|
||||
std::string mTopic;
|
||||
int mIndex;
|
||||
std::vector<JournalEntry> mEntries;
|
||||
TEntryContainer mEntries; // info-IDs
|
||||
bool mFinished;
|
||||
|
||||
public:
|
||||
|
@ -54,6 +54,8 @@ namespace MWDialogue
|
|||
|
||||
TEntryIter end();
|
||||
///< Iterator pointing past the end of the journal for this quest.
|
||||
|
||||
JournalEntry getEntry (const std::string& infoId);
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue