Changeset 584 for code/branches/FICN/src/loader
- Timestamp:
- Dec 17, 2007, 5:44:18 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/FICN/src/loader/LevelLoader.cc
r560 r584 39 39 #include "orxonox/core/Error.h" 40 40 #include "orxonox/objects/BaseObject.h" 41 #include "audio/AudioManager.h" 42 #include "orxonox/orxonox.h" 41 43 42 44 using namespace std; … … 100 102 { 101 103 TiXmlElement* loadElem; 104 TiXmlElement* audioElem; 102 105 TiXmlElement* worldElem; 103 106 TiXmlElement* tElem; … … 140 143 141 144 // Load audio 142 // TODO 143 144 // Load scripts 145 // TODO 146 145 audio::AudioManager* auMan = orxonox::Orxonox::getSingleton()->getAudioManagerPointer(); 146 audioElem = rootElement->FirstChildElement("audio"); 147 if (audioElem) 148 { 149 audioElem = audioElem->FirstChildElement("ambient"); 150 if (audioElem) 151 { 152 tNode = 0; 153 while( tNode = audioElem->IterateChildren( tNode ) ) 154 { 155 tElem = tNode->ToElement(); 156 std::string elemVal = tElem->Value(); 157 if (elemVal == "ogg") 158 { 159 auMan->ambientAdd(tElem->Attribute("src")); 160 } 161 } 162 } 163 } 164 147 165 // Load world 148 166 worldElem = rootElement->FirstChildElement("world");
Note: See TracChangeset
for help on using the changeset viewer.