Changeset 4295 in orxonox.OLD for orxonox/branches/physics
- Timestamp:
- May 26, 2005, 11:05:01 AM (20 years ago)
- Location:
- orxonox/branches/physics/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/physics/src/subprojects/particles/framework.cc
r4294 r4295 24 24 #include "debug.h" 25 25 #include "graphics_engine.h" 26 #include "resource_manager.h" 26 27 27 28 … … 259 260 mouse1Down = false; 260 261 262 ResourceManager::getInstance()->setDataDir(DATA_DIRECTORY); 261 263 262 264 // Creating a Test Particle System -
orxonox/branches/physics/src/subprojects/particles/framework.h
r4294 r4295 4 4 #include "vector.h" 5 5 #include "glincl.h" 6 7 #define DATA_DIRECTORY "~/svn/data/" 6 8 7 9 float rotatorP; -
orxonox/branches/physics/src/util/resource_manager.cc
r4223 r4295 87 87 bool ResourceManager::setDataDir(const char* dataDir) 88 88 { 89 if (isDir(dataDir)) 89 char* checkDir = ResourceManager::homeDirCheck(dataDir); 90 if (isDir(checkDir)) 90 91 { 91 92 delete this->dataDir; 92 this->dataDir = new char[strlen(dataDir)+1]; 93 strcpy(this->dataDir, dataDir); 93 this->dataDir = new char[strlen(checkDir)+1]; 94 strcpy(this->dataDir, checkDir); 95 delete checkDir; 94 96 return true; 95 97 } … … 97 99 { 98 100 PRINTF(1)("%s is not a Directory, and can not be the Data Directory, leaving as %s \n", dataDir, this->dataDir); 101 delete checkDir; 99 102 return false; 100 103 }
Note: See TracChangeset
for help on using the changeset viewer.