Changeset 6926 for code/branches/presentation3/src/orxonox/Level.cc
- Timestamp:
- May 20, 2010, 10:23:22 AM (14 years ago)
- Location:
- code/branches/presentation3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/presentation3
- Property svn:mergeinfo changed
/code/branches/lod (added) merged: 6691,6724,6786-6787,6794,6828-6829,6838-6839,6843,6852,6877,6881,6909,6911
- Property svn:mergeinfo changed
-
code/branches/presentation3/src/orxonox/Level.cc
r6746 r6926 49 49 RegisterObject(Level); 50 50 51 51 52 this->registerVariables(); 52 53 this->xmlfilename_ = this->getFilename(); … … 72 73 XMLPortParam(Level, "description", setDescription, getDescription, xmlelement, mode); 73 74 XMLPortParam(Level, "gametype", setGametypeString, getGametypeString, xmlelement, mode).defaultValues("Gametype"); 74 75 76 XMLPortObject(Level, MeshLodInformation, "lodinformation", addLodInfo, getLodInfo, xmlelement, mode); 75 77 XMLPortObjectExtended(Level, BaseObject, "", addObject, getObject, xmlelement, mode, true, false); 76 78 } 77 79 78 80 void Level::registerVariables() … … 125 127 this->objects_.push_back(object); 126 128 object->setGametype(this->getGametype()); 129 object->setLevel(this); 127 130 } 128 131 … … 136 139 ++i; 137 140 } 141 return 0; 142 } 143 144 void Level::addLodInfo(MeshLodInformation* lodInformation) 145 { 146 std::string meshName = lodInformation->getMeshName(); 147 this->lodInformation_.insert(std::make_pair(meshName,lodInformation)); 148 } 149 150 MeshLodInformation* Level::getLodInfo(std::string meshName) const 151 { 152 if(this->lodInformation_.find(meshName)!=this->lodInformation_.end()) 153 return this->lodInformation_.find(meshName)->second; 154 138 155 return 0; 139 156 }
Note: See TracChangeset
for help on using the changeset viewer.