Changeset 7810 in orxonox.OLD for trunk/src/world_entities/space_ships/helicopter.cc
- Timestamp:
- May 24, 2006, 3:57:04 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/space_ships/helicopter.cc
r7337 r7810 25 25 26 26 #include "util/loading/factory.h" 27 #include "util/loading/resource_manager.h" 28 27 29 #include "key_mapper.h" 28 30 #include "event_handler.h" … … 49 51 { 50 52 this->setPlayer(NULL); 53 54 if (this->chopperBuffer != NULL) 55 ResourceManager::getInstance()->unload(this->chopperBuffer); 51 56 } 52 57 … … 96 101 this->getWeaponManager().changeWeaponConfig(1); 97 102 dynamic_cast<Element2D*>(this->getWeaponManager().getFixedTarget())->setVisibility( false); 103 104 //load sound 105 if (this->chopperBuffer != NULL) 106 ResourceManager::getInstance()->unload(this->chopperBuffer); 107 this->chopperBuffer = (OrxSound::SoundBuffer*)ResourceManager::getInstance()->load("sound/chopper.wav", WAV); 108 98 109 } 99 110 … … 205 216 State::getCameraNode()->setParentSoft(this->getWeaponManager().getFixedTarget()); 206 217 State::getCameraTargetNode()->setParentSoft(this->getWeaponManager().getFixedTarget()); 218 219 this->soundSource.loop(this->chopperBuffer); 220 // PRINTF(0)( "Playing ChopperSound\n" ); 207 221 } 208 222 … … 211 225 dynamic_cast<Element2D*>(this->getWeaponManager().getFixedTarget())->setVisibility( false); 212 226 this->detachCamera(); 213 227 this->soundSource.stop(); 214 228 } 215 229
Note: See TracChangeset
for help on using the changeset viewer.