OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
quest.hpp
Go to the documentation of this file.
1 #ifndef GAME_MWDIALOG_QUEST_H
2 #define GAME_MWDIALOG_QUEST_H
3 
4 #include "topic.hpp"
5 
6 namespace ESM
7 {
8  struct QuestState;
9 }
10 
11 namespace MWDialogue
12 {
14  class Quest : public Topic
15  {
16  int mIndex;
17  bool mFinished;
18 
19  public:
20 
21  Quest();
22 
23  Quest (const std::string& topic);
24 
25  Quest (const ESM::QuestState& state);
26 
27  virtual std::string getName() const;
29 
30  int getIndex() const;
31 
32  void setIndex (int index);
34 
35  bool isFinished() const;
36 
37  virtual void addEntry (const JournalEntry& entry);
41 
42  void write (ESM::QuestState& state) const;
43  };
44 }
45 
46 #endif
Definition: queststate.hpp:13
virtual std::string getName() const
May be an empty string.
Definition: quest.cpp:24
void write(ESM::QuestState &state) const
Definition: quest.cpp:94
Quest()
Definition: quest.cpp:12
A dialogue entry.
Definition: journalentry.hpp:40
int getIndex() const
Definition: quest.cpp:37
A quest in progress or a completed quest.
Definition: quest.hpp:14
virtual void addEntry(const JournalEntry &entry)
Definition: quest.cpp:66
bool isFinished() const
Definition: quest.cpp:61
Collection of seen responses for a topic.
Definition: topic.hpp:17
void setIndex(int index)
Calling this function with a non-existent index will throw an exception.
Definition: quest.cpp:42
bool mFinished
Definition: quest.hpp:17
int mIndex
Definition: quest.hpp:16