Changeset 10482 in orxonox.OLD for trunk/src/world_entities/cameraman.cc
- Timestamp:
- Jan 29, 2007, 2:48:59 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/cameraman.cc
r10481 r10482 150 150 } 151 151 152 void CameraMan::atachCurrTarget(PNode* target)153 {154 currentCam->target->atach(target);155 currentCam->setViewMode(Camera::ViewNormal);156 State::setCamera(this->currentCam, dynamic_cast<CameraTarget*>(target));157 158 }159 152 160 153 void CameraMan::atachCurrCameraToWorldEntity(const std::string& className, const std::string& targetEntity) … … 164 157 if(object != NULL && object->isA(PNode::staticClassID())) 165 158 { 166 this->atach CurrTarget(dynamic_cast<PNode*>(object));159 this->atachTarget(this->currentCam, dynamic_cast<PNode*>(object)); 167 160 return; 168 161 } … … 233 226 if( object != NULL && targetCam != NULL && object->isA(PNode::staticClassID()) ) 234 227 { 235 dynamic_cast<Camera*>(targetCam)->target->atach(dynamic_cast<PNode*>(object)); 236 dynamic_cast<Camera*>(targetCam)->setViewMode(Camera::ViewNormal); 237 State::setCamera(dynamic_cast<Camera*>(targetCam), dynamic_cast<CameraTarget*>(object)); 228 this->atachTarget(dynamic_cast<Camera*>(targetCam), dynamic_cast<PNode*>( object )); 238 229 return; 239 230 } … … 304 295 305 296 297 void CameraMan::atachTarget(Camera* cam ,PNode* target) 298 { 299 cam->target->atach(target); 300 cam->setViewMode(Camera::ViewNormal); 301 State::setCamera( cam, dynamic_cast<CameraTarget*>(target)); 302 303 } 304 306 305 //how to get a class fkt pointer 307 306
Note: See TracChangeset
for help on using the changeset viewer.