- Timestamp:
- Dec 14, 2008, 1:42:17 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/presentation/src/orxonox/objects/quest/QuestListener.h
r2385 r2435 28 28 29 29 /** 30 @file QuestListener.h30 @file 31 31 @brief Definition of the QuestListener class. 32 32 */ … … 44 44 #include "Quest.h" 45 45 46 namespace questListenerMode46 namespace orxonox 47 47 { 48 namespace questListenerMode 49 { 48 50 49 //! The mode of the QuestListener.50 enum Enum51 {52 all,53 start,54 fail,55 complete56 };51 //! The mode of the QuestListener. 52 enum Enum 53 { 54 all, 55 start, 56 fail, 57 complete 58 }; 57 59 58 } 59 60 namespace orxonox { 60 } 61 61 62 62 /** … … 75 75 </BaseObject> 76 76 @author 77 77 Damian 'Mozork' Frick 78 78 */ 79 79 class _OrxonoxExport QuestListener : public BaseObject 80 80 { 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 81 public: 82 QuestListener(BaseObject* creator); 83 virtual ~QuestListener(); 84 85 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); //!< Method for creating a QuestListener object through XML. 86 87 static void advertiseStatusChange(std::list<QuestListener*> & listeners, const std::string & status); //!< Makes all QuestListener in the list aware that a certain status change has occured. 88 89 bool setQuestId(const std::string & id); //!< Sets the questId of the Quest the QuestListener reacts to. 90 bool setMode(const std::string & mode); //!< Sets the mode of the QuestListener. 91 92 const std::string getMode(void); //!< Get the mode of the QuestListener. 93 94 /** 95 @brief Get the questId of the Quest the QuestListener reacts to. 96 @return Returns the questId of the Quest the QuestListener reacts to. 97 */ 98 inline const std::string & getQuestId(void) 99 99 { return this->quest_->getId(); } 100 101 102 103 104 105 100 101 bool execute(void); //!< Executes the QuestListener, resp. fires an Event. 102 103 private: 104 questListenerMode::Enum mode_; //!< The mode of the QuestListener. 105 Quest* quest_; //!< A pointer to the Quest the QuestListener is reacting to. 106 106 107 107 };
Note: See TracChangeset
for help on using the changeset viewer.