Changeset 6387 for code/branches/presentation2/src/orxonox
- Timestamp:
- Dec 21, 2009, 1:18:36 PM (15 years ago)
- Location:
- code/branches/presentation2/src/orxonox
- Files:
-
- 32 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/presentation2/src/orxonox/MoodManager.cc
r6370 r6387 64 64 ModifyConfigValue(mood_, set, mood); 65 65 } 66 66 67 67 //! Gets the current mood 68 68 const std::string& MoodManager::getMood() -
code/branches/presentation2/src/orxonox/PlayerManager.cc
r6182 r6387 90 90 } 91 91 } 92 92 93 93 void PlayerManager::disconnectAllClients() 94 94 { -
code/branches/presentation2/src/orxonox/Scene.h
r6372 r6387 78 78 inline Radar* getRadar() 79 79 { return this->radar_; } 80 80 81 81 inline virtual uint32_t getSceneID() const { return this->getObjectID(); } 82 82 -
code/branches/presentation2/src/orxonox/Test.h
r6123 r6387 75 75 void checkS3(); 76 76 void checkS4(); 77 77 78 78 void printPointer(); 79 79 … … 95 95 TYPE s3; 96 96 TYPE s4; 97 97 98 98 Test* pointer_; 99 99 -
code/branches/presentation2/src/orxonox/controllers/ArtificialController.cc
r6164 r6387 46 46 this->bHasTargetPosition_ = false; 47 47 this->targetPosition_ = Vector3::ZERO; 48 48 49 49 this->target_.setCallback(createFunctor(&ArtificialController::targetDied, this)); 50 50 } … … 143 143 this->targetPosition_ = getPredictedPosition(this->getControllableEntity()->getPosition(), hardcoded_projectile_speed, this->target_->getPosition(), this->target_->getVelocity()); 144 144 this->bHasTargetPosition_ = (this->targetPosition_ != Vector3::ZERO); 145 145 146 146 Pawn* pawn = dynamic_cast<Pawn*>(this->getControllableEntity()); 147 147 if (pawn) -
code/branches/presentation2/src/orxonox/controllers/ArtificialController.h
r5929 r6387 42 42 ArtificialController(BaseObject* creator); 43 43 virtual ~ArtificialController(); 44 44 45 45 void abandonTarget(Pawn* target); 46 46 -
code/branches/presentation2/src/orxonox/controllers/Controller.h
r6356 r6387 51 51 52 52 virtual inline void hit(Pawn* originator, btManifoldPoint& contactpoint, float damage) {}; 53 53 54 54 void setGodMode( bool mode ){ this->bGodMode_ = mode; } 55 55 bool getGodMode(){ return this->bGodMode_; } -
code/branches/presentation2/src/orxonox/controllers/NewHumanController.cc
r6377 r6387 140 140 arrowsOverlay1_->setPosition(Vector2(0.5, 0.5)); 141 141 arrowsOverlay1_->hide(); 142 142 143 143 arrowsOverlay2_ = new OrxonoxOverlay(this); 144 144 arrowsOverlay2_->setBackgroundMaterial("Orxonox/DirectionArrows2"); … … 147 147 arrowsOverlay2_->setPosition(Vector2(0.5, 0.5)); 148 148 arrowsOverlay2_->hide(); 149 149 150 150 arrowsOverlay3_ = new OrxonoxOverlay(this); 151 151 arrowsOverlay3_->setBackgroundMaterial("Orxonox/DirectionArrows3"); … … 154 154 arrowsOverlay3_->setPosition(Vector2(0.5, 0.5)); 155 155 arrowsOverlay3_->hide(); 156 156 157 157 arrowsOverlay4_ = new OrxonoxOverlay(this); 158 158 arrowsOverlay4_->setBackgroundMaterial("Orxonox/DirectionArrows4"); … … 502 502 { 503 503 hideArrows(); 504 504 505 505 float distance = sqrt(pow(static_cast<float>(this->currentYaw_)/2*-1,2) + pow(static_cast<float>(this->currentPitch_)/2*-1,2)); 506 506 507 507 if (distance > 0.04 && distance <= 0.59 * arrowsSize_ / 2.0 ) 508 508 { -
code/branches/presentation2/src/orxonox/gamestates/GSGraphics.cc
r6150 r6387 64 64 void GSGraphics::activate() 65 65 { 66 66 67 67 } 68 68 -
code/branches/presentation2/src/orxonox/gamestates/GSLevel.cc
r6150 r6387 90 90 // level is loaded: we can start capturing the input 91 91 InputManager::getInstance().enterState("game"); 92 92 93 93 // connect the HumanPlayer to the game 94 94 PlayerManager::getInstance().clientConnected(0); … … 105 105 InputManager::getInstance().leaveState("game"); 106 106 } 107 107 108 108 // disconnect all HumanPlayers 109 109 PlayerManager::getInstance().disconnectAllClients(); … … 135 135 for (ObjectList<BaseObject>::iterator it = ObjectList<BaseObject>::begin(); it != ObjectList<BaseObject>::end(); ++it) 136 136 this->staticObjects_.insert(*it); 137 137 138 138 // call the loader 139 139 COUT(0) << "Loading level..." << std::endl; -
code/branches/presentation2/src/orxonox/gamestates/GSMainMenu.cc
r6378 r6387 96 96 CommandExecutor::addConsoleCommandShortcut(createConsoleCommand(createFunctor(&GSMainMenu::startDedicated), "startDedicated")); 97 97 CommandExecutor::addConsoleCommandShortcut(createConsoleCommand(createFunctor(&GSMainMenu::startMainMenu), "startMainMenu")); 98 98 99 99 // create command to change sound path 100 100 CommandExecutor::addConsoleCommandShortcut(createConsoleCommand(createFunctor(&GSMainMenu::setMainMenuSoundPath, this), "setMMSoundPath")); -
code/branches/presentation2/src/orxonox/gamestates/GSRoot.cc
r6378 r6387 55 55 NetworkFunctionBase::destroyAllNetworkFunctions(); 56 56 } 57 57 58 58 void GSRoot::printObjects() 59 59 { -
code/branches/presentation2/src/orxonox/gametypes/Gametype.cc
r5929 r6387 51 51 { 52 52 RegisterObject(Gametype); 53 53 54 54 this->gtinfo_ = new GametypeInfo(creator); 55 55 … … 79 79 else 80 80 this->scoreboard_ = 0; 81 81 82 82 /* HACK HACK HACK */ 83 83 this->hackAddBots_ = createConsoleCommand( createFunctor(&Gametype::addBots, this), "hackAddBots"); … … 87 87 /* HACK HACK HACK */ 88 88 } 89 89 90 90 Gametype::~Gametype() 91 91 { -
code/branches/presentation2/src/orxonox/gametypes/Gametype.h
r5929 r6387 184 184 // Config Values 185 185 std::string scoreboardTemplate_; 186 186 187 187 /* HACK HACK HACK */ 188 188 ConsoleCommand* hackAddBots_; -
code/branches/presentation2/src/orxonox/infos/PlayerInfo.cc
r6192 r6387 171 171 this->changedControllableEntity(); 172 172 } 173 173 174 174 void PlayerInfo::startTemporaryControl(ControllableEntity* entity) 175 175 { 176 176 if (!entity) 177 177 return; 178 178 179 179 // assert( this->temporaryControllableEntity_==0 ); 180 180 … … 195 195 if ( this->oldControllableEntity_ ) 196 196 this->stopTemporaryControl(); 197 197 198 198 ControllableEntity* entity = this->controllableEntity_; 199 199 … … 213 213 this->changedControllableEntity(); 214 214 } 215 215 216 216 void PlayerInfo::stopTemporaryControl() 217 217 { … … 231 231 if ( GameMode::isMaster() ) 232 232 entity->removePlayer(); 233 234 this->changedControllableEntity(); 235 } 236 233 234 this->changedControllableEntity(); 235 } 236 237 237 void PlayerInfo::networkcallback_changedcontrollableentityID() 238 238 { -
code/branches/presentation2/src/orxonox/interfaces/Rewardable.h
r5781 r6387 43 43 @brief 44 44 Rewardable is an Interface, that can be implemented by any object to enable it to be given as reward to a player through QuestEffects. (With the AddReward effect.) 45 45 46 46 It just needs to inherit form Rewardable, and implement the reward() method. 47 47 @author -
code/branches/presentation2/src/orxonox/items/MultiStateEngine.h
r6329 r6387 64 64 void addEffectContainer(EffectContainer* effect); 65 65 EffectContainer* getEffectContainer(unsigned int index) const; 66 66 67 67 void setDefEngSndNormal(const std::string& engineSound); 68 68 const std::string& getDefEngSndNormal(); -
code/branches/presentation2/src/orxonox/overlays/OrxonoxOverlay.cc
r6310 r6387 171 171 { 172 172 SUPER( OrxonoxOverlay, changedVisibility ); 173 173 174 174 if (!this->overlay_) 175 175 return; -
code/branches/presentation2/src/orxonox/overlays/OverlayGroup.cc
r6054 r6387 144 144 { 145 145 SUPER( OverlayGroup, changedVisibility ); 146 146 147 147 for (std::set< SmartPtr<OrxonoxOverlay> >::iterator it = hudElements_.begin(); it != hudElements_.end(); ++it) 148 148 (*it)->changedVisibility(); //inform all Child Overlays that our visibility has changed -
code/branches/presentation2/src/orxonox/pickup/ModifierPickup.h
r5929 r6387 129 129 130 130 void timerCallback(Pawn* pawn); //!< Method called when the timer runs out. 131 131 132 132 private: 133 133 float getAdditiveModifier(ModifierType::Value type) const; //!< Get the additive modifier for a given ModifierType. -
code/branches/presentation2/src/orxonox/pickup/UsableItem.cc
r5781 r6387 26 26 * 27 27 */ 28 28 29 29 /** 30 30 @file -
code/branches/presentation2/src/orxonox/sound/AmbientSound.cc
r6382 r6387 61 61 } 62 62 } 63 63 64 64 void AmbientSound::registerVariables() 65 65 { … … 101 101 SoundManager::getInstance().pauseAmbientSound(this); 102 102 } 103 103 104 104 float AmbientSound::getRealVolume() 105 105 { -
code/branches/presentation2/src/orxonox/sound/BaseSound.cc
r6383 r6387 150 150 this->updateVolume(); 151 151 } 152 152 153 153 void BaseSound::updateVolume() 154 154 { … … 252 252 } 253 253 } 254 254 255 255 void BaseSound::stateChanged() 256 256 { -
code/branches/presentation2/src/orxonox/sound/SoundManager.cc
r6383 r6387 134 134 else 135 135 COUT(2) << "Sound Warning: MIME Type retrieval failed: " << alutGetErrorString(alutGetError()) << std::endl; 136 136 137 137 this->mute_[SoundType::All] = 1.0f; 138 138 this->mute_[SoundType::Music] = 1.0f; … … 431 431 void SoundManager::processCrossFading(float dt) 432 432 { 433 433 434 434 // Hacky solution to the fade delay while loading a level. 435 435 if(dt > 0.2) … … 437 437 return; 438 438 } 439 439 440 440 // FADE IN 441 441 for (std::list<SmartPtr<AmbientSound> >::iterator it= this->fadeInList_.begin(); it != this->fadeInList_.end(); ) -
code/branches/presentation2/src/orxonox/sound/SoundManager.h
r6383 r6387 75 75 void preUpdate(const Clock& time); 76 76 void setConfigValues(); 77 77 78 78 // tolua_begin 79 79 static SoundManager& getInstance() { return Singleton<SoundManager>::getInstance(); } -
code/branches/presentation2/src/orxonox/sound/WorldSound.cc
r6382 r6387 51 51 this->registerVariables(); 52 52 } 53 53 54 54 void WorldSound::registerVariables() 55 55 { -
code/branches/presentation2/src/orxonox/weaponsystem/WeaponMode.cc
r6381 r6387 67 67 68 68 this->damage_ = 0; 69 69 70 70 this->muzzleOffset_ = Vector3::ZERO; 71 71 this->muzzlePosition_ = Vector3::ZERO; … … 141 141 this->defSndWpnFire_->play(); 142 142 } 143 143 144 144 this->fire(); 145 145 -
code/branches/presentation2/src/orxonox/worldentities/ControllableEntity.cc
r6325 r6387 238 238 this->cameraPositionRootNode_->roll(Radian(value.y * this->mouseLookSpeed_), Ogre::Node::TS_LOCAL); 239 239 } 240 240 241 241 void ControllableEntity::fire(unsigned int firemode) 242 242 { … … 250 250 } 251 251 } 252 252 253 253 void ControllableEntity::setTarget( WorldEntity* target ) 254 254 { … … 266 266 } 267 267 } 268 268 269 269 void ControllableEntity::setTargetInternal( uint32_t targetID ) 270 270 { -
code/branches/presentation2/src/orxonox/worldentities/ControllableEntity.h
r6325 r6387 145 145 inline void setController(Controller* val) 146 146 { this->controller_ = val; } 147 147 148 148 virtual void setTarget( WorldEntity* target ); 149 149 virtual WorldEntity* getTarget() -
code/branches/presentation2/src/orxonox/worldentities/StaticEntity.cc
r5781 r6387 42 42 { 43 43 RegisterObject(StaticEntity); 44 44 45 45 this->setPriority(Priority::VeryLow); 46 46 -
code/branches/presentation2/src/orxonox/worldentities/pawns/Pawn.cc
r6356 r6387 68 68 69 69 this->spawnparticleduration_ = 3.0f; 70 70 71 71 this->aimPosition_ = Vector3::ZERO; 72 72 -
code/branches/presentation2/src/orxonox/worldentities/pawns/Pawn.h
r6295 r6387 116 116 117 117 virtual void startLocalHumanControl(); 118 118 119 119 void setAimPosition( Vector3 position ) 120 120 { this->aimPosition_ = position; } … … 153 153 inline void setWeaponSystem(WeaponSystem* weaponsystem) 154 154 { this->weaponSystem_ = weaponsystem; } 155 155 156 156 Vector3 aimPosition_; 157 157 };
Note: See TracChangeset
for help on using the changeset viewer.