Changeset 469 for AE/Installer/trunk/source/main_window.cpp
- Timestamp:
- Oct 21, 2009, 12:55:16 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
AE/Installer/trunk/source/main_window.cpp
r462 r469 196 196 logfile << "Exporting and moving...\n\n"; 197 197 int total_steps = 8 + 2 * num_levels; 198 198 199 for(int i = 0; i < 15; i++) 199 200 { … … 211 212 create_directory( "VanillaDats/level" + levels[i] + "_Final" ); 212 213 create_directory( "VanillaDats/level" + levels[i] + "_Final/level" + levels[i] + "_Final" ); 214 215 //Moves the AKEV and other files into a safe directory so that level specific textures are not globalized... 216 if ( strcmp(levels[i].c_str(), "0") ){ 217 create_directory( "../GameDataFolder/level" + levels[i] + "_Final/AKEV" ); 218 system((strOniSplit + " -move:overwrite ../GameDataFolder/level" + levels[i] + "_Final/AKEV ../GameDataFolder/level" + levels[i] + "_Final/AKEV*.oni").c_str()); 219 220 } 213 221 214 222 directory_iterator end_iter; … … 306 314 307 315 } 316 308 317 logfile << "\tCleaning up TXMPs...\n"; 309 318 system( (strOniSplit + " -move:delete " + Textures.string() + " ../GameDataFolder/level" + levels[i] + "_Final/TXMP*.oni").c_str()); 319 320 321 if ( strcmp(levels[i].c_str(), "0") ){ 322 system((strOniSplit + " -move:overwrite ../GameDataFolder/level" + levels[i] + "_Final ../GameDataFolder/level" + levels[i] + "_Final/AKEV/AKEV*.oni").c_str()); 323 remove( "../GameDataFolder/level" + levels[i] + "_Final/AKEV" ); 324 } 325 310 326 parts_done++; 311 327 … … 345 361 setStatusArea("Step " + lexical_cast<std::string>(parts_done + 1) + "/" + lexical_cast<std::string>(total_steps) + ": moving level0_Characters" ); 346 362 copy((path)"../GameDataFolder/level0_Characters", (path)("VanillaDats/level0_Final")); 363 GDFPaths.push_back( Characters ); 364 for(int i = 0; i < GDFPaths.size(); i++) 365 { 366 directory_iterator end_iter; 367 for ( directory_iterator dir_itr( GDFPaths[i] ); dir_itr != end_iter; ++dir_itr ) 368 { 369 try 370 { 371 372 373 rename(dir_itr->path(), "../GameDataFolder/level0_Final/" + dir_itr->path().filename() ); 374 } 375 catch(exception &ex) { 376 377 } 378 } 379 } 347 380 /* 348 381 printf(Step_x_x,"Step %d/%d: reimporting level0_Characters", parts_done,7 + 2 * num_levels); setStatusArea((string)Step_x_x);setProgressBar( (int)(1000 * (float)(parts_done) / (float)(7 + 2 * num_levels) )); … … 367 400 368 401 if(exists("../../persist.dat")) if(!exists("../persist.dat")) 402 403 //TODO: Concactate level0 Dirs. 404 369 405 copy("../../persist.dat",".."); 370 406 if(exists("../../key_config.txt"))if(!exists("../key_config.txt"))
Note:
See TracChangeset
for help on using the changeset viewer.