Changeset 10292 in orxonox.OLD for branches/heathaze
- Timestamp:
- Jan 18, 2007, 3:14:52 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/heathaze/src/lib/script_engine/script.cc
r9916 r10292 93 93 bool Script::loadFile(const std::string& filename) 94 94 { 95 96 int seperation = filename.find_first_of('/'); 97 std::string directory = filename.substr( seperation, 0 ); 98 std::string file = filename.substr( seperation ); 99 100 printf("Directory is %s \n", directory.c_str()); 101 printf("File is %s \n", file.c_str()); 102 95 103 std::string filedest(Resources::ResourceManager::getInstance()->mainGlobalPath().name()); 96 filedest += "/scripts/" + filename;104 filedest += "/scripts/" + directory + filename; 97 105 98 106 this->addThisScript(); … … 109 117 if(error == 0) 110 118 { 111 currentFile = file name;119 currentFile = file; 112 120 error = lua_pcall(luaState, 0, 0, 0); 113 121
Note: See TracChangeset
for help on using the changeset viewer.