Changeset 10259 in orxonox.OLD for branches/camera/src/story_entities
- Timestamp:
- Jan 17, 2007, 3:46:05 PM (18 years ago)
- Location:
- branches/camera/src/story_entities
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/camera/src/story_entities/game_world_data.cc
r9869 r10259 70 70 this->glmis = NULL; 71 71 72 this->localCamera = NULL; 72 73 73 this->localPlayer = NULL; 74 74 this->sky = NULL; … … 98 98 99 99 PNode::getNullParent(); 100 this->localCamera = new Camera();101 this->localCamera->setName ("GameWorld-Camera");102 State::setCamera( this->localCamera, this->localCamera->getTarget());100 Camera* localCamera = new Camera(); 101 localCamera->setName ("GameWorld-Camera"); 102 State::setCamera(localCamera, localCamera->getTarget()); 103 103 104 104 LightManager::getInstance(); … … 232 232 State::setPlayer(this->localPlayer); 233 233 234 Playable* playable;235 234 if (!Playable::objectList().empty()) 236 235 { … … 284 283 State::setPlayer(NULL); 285 284 this->localPlayer = NULL; 286 this->localCamera = NULL;287 285 State::setCamera(NULL, NULL); 288 286 this->sky = NULL; … … 334 332 LoadParamXML(root, "GameRule", this, GameWorldData, loadGameRule); 335 333 336 LoadParam(root, "clip-region", this->localCamera, Camera, setClipRegion);334 LoadParam(root, "clip-region", State::getCamera(), Camera, setClipRegion); 337 335 338 336 … … 340 338 //LoadParamXML(root, "PhysicsEngine", PhysicsEngine::getInstance(), PhysicsEngine, loadParams); 341 339 342 if( this->sky != NULL) 343 this->localCamera->addChild(this->sky); 344 OrxSound::SoundEngine::getInstance()->setListener(this->localCamera); 340 341 OrxSound::SoundEngine::getInstance()->setListener(State::getCamera()); 345 342 346 343 return ErrorMessage(); -
branches/camera/src/story_entities/game_world_data.h
r9869 r10259 56 56 GLMenuImageScreen* glmis; //!< The Level-Loader Display 57 57 58 Camera* localCamera; //!< The current camera 58 59 59 Player* localPlayer; //!< The player, you fly through the level. 60 60 WorldEntity* sky; //!< The environmental sky of orxonox -
branches/camera/src/story_entities/menu/game_menu.cc
r9869 r10259 110 110 this->subscribeEvent(ES_MENU, SDLK_ESCAPE); 111 111 112 this->dataTank->localCamera->setRelCoor(this->cameraVector);112 State::getCamera()->setRelCoor(this->cameraVector); 113 113 114 114 GraphicsEngine::getInstance()->displayFPS(false); … … 390 390 Quaternion q(/*0.00005*/ dt * .1, Vector(0.0, 1.0, 0.0)); 391 391 this->cameraVector = q.apply(this->cameraVector); 392 this->dataTank->localCamera->setRelCoor(this->cameraVector);393 this->dataTank->localCamera->getTarget()->setRelCoorSoft(0,0,0);392 State::getCamera()->setRelCoor(this->cameraVector); 393 State::getCamera()->getTarget()->setRelCoorSoft(0,0,0); 394 394 } 395 395
Note: See TracChangeset
for help on using the changeset viewer.