Changeset 546
- Timestamp:
- Dec 16, 2007, 10:19:03 PM (17 years ago)
- Location:
- code/branches/FICN/src/orxonox
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/FICN/src/orxonox/graphicsEngine.cc
r473 r546 113 113 for (i = settings->begin(); i != settings->end(); ++i) 114 114 { 115 typeName = i->first; 116 archName = i->second; 115 typeName = i->first; // for instance "FileSystem" or "Zip" 116 archName = i->second; // name (and location) of archive 117 117 118 118 ResourceGroupManager::getSingleton().addResourceLocation( 119 119 String(dataPath + archName), 120 typeName, secName);120 typeName, secName); 121 121 } 122 122 } -
code/branches/FICN/src/orxonox/main.cc
r544 r546 71 71 #endif 72 72 73 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 74 #define WIN32_LEAN_AND_MEAN 75 #include "windows.h" 73 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 74 #define WIN32_LEAN_AND_MEAN 75 #include "windows.h" 76 76 INT WINAPI WinMain(HINSTANCE hInst, HINSTANCE, LPSTR strCmdLine, INT) 77 77 { 78 // something like this would be less hacky 79 // maybe one can work with trailing '\0' 80 // or maybe use string based functions 81 // I was unable to test it without working windows version 82 /*char* cmd = strCmdLine; 83 int argc = 1; 84 for(int i = 0; cmd[i] != NULL; i++) 85 { 86 if(cmd[i] == ' ') argc++; 87 } 88 char* argv[argc]; 89 int j = 0; 90 int k = 0; 91 for(int i = 0; cmd[i] != NULL; i++) 92 { 93 if(cmd[i] != ' ') { 94 argv[j][k]; 95 k++; 96 } 97 else { 98 k = 0; 99 j++; 100 } 101 }*/ 78 102 char *argv[2]; 79 argv[0] = "asdf programName";103 argv[0] = "asdfProgram"; 80 104 argv[1] = strCmdLine; 81 105 int argc = 2; 82 #else 83 int main(int argc, char **argv) 106 #else 107 int main(int argc, char **argv) 84 108 { 85 #endif 109 #endif 86 110 try { 87 111 SignalHandler::getInstance()->doCatch(argv[0], "orxonox.log"); … … 96 120 } 97 121 catch (Ogre::Exception& e) { 98 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 122 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 99 123 MessageBoxA(NULL, e.getFullDescription().c_str(), 100 124 "An exception has occured!", MB_OK | MB_ICONERROR | MB_TASKMODAL); -
code/branches/FICN/src/orxonox/orxonox.cc
r545 r546 193 193 { 194 194 ogre_ = new GraphicsEngine(); 195 dataPath_ = ""; 195 196 } 196 197 … … 217 218 ArgReader ar = ArgReader(argc, argv); 218 219 ar.checkArgument("mode", mode, false); 219 // ar.checkArgument("data-path", path, true);220 ar.checkArgument("data", this->dataPath_, false); 220 221 if(ar.errorHandling()) die(); 221 222 … … 354 355 cf.load(macBundlePath() + "/Contents/Resources/resources.cfg"); 355 356 #else 356 cf.load( "resources.cfg");357 cf.load(dataPath_ + "resources.cfg"); 357 358 #endif 358 359 … … 378 379 void Orxonox::setupRenderSystem() 379 380 { 380 if ( !root_->restoreConfig() &&!root_->showConfigDialog())381 if (/*!root_->restoreConfig() &&*/ !root_->showConfigDialog()) 381 382 throw Exception(52, "User canceled the config dialog!", "OrxApplication::setupRenderSystem()"); 382 383 }
Note: See TracChangeset
for help on using the changeset viewer.