- Timestamp:
- Jan 27, 2007, 10:52:56 PM (18 years ago)
- Location:
- trunk/src/world_entities
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/cameraman.cc
r10414 r10416 35 35 ->addMethod("atachCurrCameraToWorldEntity", Executor2<CameraMan, lua_State*,const std::string&,const std::string&>(&CameraMan::atachCurrCameraToWorldEntity)) 36 36 ->addMethod("changeTarget", Executor3<CameraMan, lua_State*, const std::string&, const std::string&,const std::string&>(&CameraMan::changeTarget)) 37 ->addMethod("atachCameraToWorldEntity", Executor3<CameraMan, lua_State*,const std::string&,const std::string&,const std::string&>(&CameraMan::atachCameraToWorldEntity)) 37 38 ->addMethod("detachCurrCamera", Executor0<CameraMan, lua_State*>(&CameraMan::detachCurrCamera)) 38 39 ->addMethod("setCam", Executor1<CameraMan, lua_State*, const std::string&>(&CameraMan::setCam)) … … 182 183 } 183 184 184 printf("ERROR CAMERAMANAGER: Couldn't set camera target to: %s %s \n", className.c_str(),targetEntity.c_str() ); 185 } 185 printf("ERROR CAMERAMANAGER: Couldn't set camera to: %s %s \n", className.c_str(),targetEntity.c_str() ); 186 } 187 188 189 void CameraMan::atachCameraToWorldEntity(const std::string& cameraName, const std::string& className, const std::string& targetEntity) 190 { 191 BaseObject* object = ObjectListBase::getBaseObject(className, targetEntity); 192 BaseObject* targetCam = ObjectListBase::getBaseObject("Camera", cameraName); 193 194 if(object != NULL && targetCam != NULL) 195 { 196 dynamic_cast<Camera*>(targetCam)->target->atach(dynamic_cast<PNode*>(object)); 197 return; 198 } 199 200 printf("ERROR CAMERAMANAGER: Couldn't set camera %s to: %s %s \n", cameraName.c_str(), className.c_str(),targetEntity.c_str() ); 201 } 202 186 203 187 204 void CameraMan::detachCurrCamera() -
trunk/src/world_entities/cameraman.h
r10414 r10416 35 35 void atachCurrTarget(PNode* target); 36 36 void atachCurrCameraToWorldEntity(const std::string& className, const std::string& targetEntity); 37 void atachCameraToWorldEntity(const std::string& cameraName, const std::string& className, const std::string& targetEntity); 37 38 void detachCurrCamera(); 38 39 void jumpCam(int x, int y, int z, int camNo);
Note: See TracChangeset
for help on using the changeset viewer.