Changeset 2092 for code/trunk/src/orxonox/objects/quest/QuestManager.cc
- Timestamp:
- Nov 1, 2008, 8:32:10 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/orxonox/objects/quest/QuestManager.cc
r2091 r2092 37 37 std::map<std::string, QuestHint*> QuestManager::hintMap_; 38 38 39 QuestManager::QuestManager( ) : BaseObject()39 QuestManager::QuestManager(BaseObject* creator) : BaseObject(creator) 40 40 { 41 41 RegisterObject(QuestManager); 42 42 } 43 44 43 44 45 45 QuestManager::~QuestManager() 46 46 { 47 47 48 48 } 49 49 … … 63 63 return false; 64 64 } 65 65 66 66 std::pair<std::map<std::string, Quest*>::iterator,bool> ret; 67 67 ret = questMap_.insert( std::pair<std::string,Quest*>(quest->getId(),quest) ); 68 68 69 69 if(ret.second) 70 70 { … … 78 78 } 79 79 } 80 80 81 81 /** 82 82 @brief … … 94 94 return false; 95 95 } 96 96 97 97 std::pair<std::map<std::string, QuestHint*>::iterator,bool> ret; 98 98 ret = hintMap_.insert ( std::pair<std::string,QuestHint*>(hint->getId(),hint) ); 99 99 100 100 if(ret.second) 101 101 { … … 109 109 } 110 110 } 111 111 112 112 /** 113 113 @brief … … 127 127 ThrowException(Argument, "Invalid questId."); 128 128 } 129 129 130 130 Quest* quest; 131 131 std::map<std::string, Quest*>::iterator it = questMap_.find(questId); … … 139 139 COUT(2) << "The quest with id {" << questId << "} is nowhere to be found." << std::endl; 140 140 } 141 141 142 142 return quest; 143 143 144 144 } 145 145 146 146 /** 147 147 @brief … … 161 161 ThrowException(Argument, "Invalid hintId."); 162 162 } 163 163 164 164 QuestHint* hint; 165 165 std::map<std::string, QuestHint*>::iterator it = hintMap_.find(hintId); … … 173 173 COUT(2) << "The hint with id {" << hintId << "} is nowhere to be found." << std::endl; 174 174 } 175 175 176 176 return hint; 177 177 178 178 } 179 179 180 180 181 181 }
Note: See TracChangeset
for help on using the changeset viewer.