Changeset 4115 in orxonox.OLD for orxonox/trunk
- Timestamp:
- May 7, 2005, 10:13:19 PM (20 years ago)
- Location:
- orxonox/trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/util/resource_manager.cc
r4091 r4115 202 202 // searching if the resource was loaded before. 203 203 Resource* tmpResource = this->locateResourceByInfo(fileName, type, param1, param2,param3); 204 if (tmpResource) // if the resource was notloaded before.204 if (tmpResource) // if the resource was loaded before. 205 205 { 206 206 PRINTF(4)("not loading cached resource %s\n", tmpResource->name); … … 221 221 222 222 // creating the full name. (directoryName + FileName) 223 char* fullName = new char[strlen( dataDir)+strlen(fileName)+1];224 sprintf(fullName, "%s%s", this-> dataDir, fileName);225 223 char* fullName = new char[strlen(this->getDataDir())+strlen(fileName)+1]; 224 sprintf(fullName, "%s%s", this->getDataDir(), fileName); 225 printf("FULLNAME: %s\n", fullName); 226 226 // Checking for the type of resource \see ResourceType 227 227 switch(type) … … 233 233 tmpResource->modelSize = 1.0; 234 234 235 if( isFile(fullName))235 if(ResourceManager::isFile(fullName)) 236 236 tmpResource->pointer = new OBJModel(fullName, tmpResource->modelSize); 237 237 else -
orxonox/trunk/src/util/resource_manager.h
r4091 r4115 66 66 bool setDataDir(const char* dataDir); 67 67 /** \returns the Name of the data directory */ 68 const char* getDataDir(void) {return this->dataDir;}68 inline const char* getDataDir(void) {return this->dataDir;} 69 69 bool checkDataDir(const char* fileInside); 70 70 bool addImageDir(char* imageDir); -
orxonox/trunk/src/world_entities/world_entity.cc
r4114 r4115 65 65 this->model = NULL; 66 66 string = grabParameter( root, "model"); 67 printf("::::::::::::::::::::::string is %s\n", string);68 67 if( string != NULL) 69 68 this->model = (Model*)ResourceManager::getInstance()->load(string, OBJ, RP_CAMPAIGN);
Note: See TracChangeset
for help on using the changeset viewer.