home *** CD-ROM | disk | FTP | other *** search
/ UnrealScript Game Programming All in One / UnrealScriptGameProgrammingAllInOne.iso / UGPAIOListings / CH08LIST_BACKUP / System / copyCustomIni.bat next >
Encoding:
DOS Batch File  |  2006-01-24  |  1.0 KB  |  52 lines

  1.  
  2.  
  3.  
  4. echo off
  5. @rem copyCustomIni.bat
  6. rem #1
  7. cls
  8. echo Copy your local *ini to your UT System dir...
  9. echo File to be used: %1
  10. echo -----------------------------------------------
  11.  
  12. if "%1"=="" (
  13.   echo You must enter the package to 
  14.   echo use as the basis of the *.ini 
  15.   echo file name
  16.   goto ERROR
  17.   rem go to the end, no action.
  18. )
  19.  
  20. if "%2"=="" (
  21.   echo You must provide the path to the UT2004 directory
  22.   goto ERROR
  23. )
  24.  
  25. rem #2
  26.  
  27. echo Deleting %2\%1\UT2004_%1.ini_old ...
  28. if exist "%2\%1\UT2004_%1.ini_old" DEL "%2\%1\UT2004_%1.ini_old"
  29.  
  30. echo Saviing %2\%1\UT2004_%1.ini 
  31. echo        to %2\%1\UT2004_%1.ini_old ...
  32.  
  33. rem if a current copy exists in System, save it to old locally
  34. copy "%2\%1\UT2004_%1.ini" "%2\%1\UT2004_%1.ini_old"
  35.  
  36. rem #3
  37.  
  38. echo Copying the local ini to the System Ini...
  39. iF exist "%2\%1\UT2004_%1.ini" copy "%2\%1\UT2004_%1.ini" "%2\System\UT2004_%1.ini"
  40.  
  41.  
  42. rem #4
  43. echo %2\%1\UT2004_%1.ini file copied to your System directory
  44. dir "%2\System\U*_*.ini"
  45.  
  46.  
  47.  
  48. :ERROR
  49.  
  50. rem console testing use
  51. rem pause
  52. exit