home *** CD-ROM | disk | FTP | other *** search
/ PC Gamer 7 / 1995-06_Disc_7.iso / xcomii / install.bat < prev    next >
DOS Batch File  |  1995-04-06  |  2KB  |  89 lines

  1. @echo off
  2. cls
  3.  
  4. REM Checkimg for proper command line usage.
  5. if "%1" == "" goto usage
  6.  
  7. REM Checking for enough drive space.
  8. disksize %1 4000000
  9. if errorlevel 1 goto usage2
  10.  
  11. REM Checking for Proper Drive
  12. if not exist tftd.zip goto usage3
  13.  
  14. REM Creating Install Directory
  15. md %1\mps
  16. md %1\mps\tftd
  17. if not exist %1\mps\tftd\nul goto error1
  18.  
  19. REM Installing UPDATE Software
  20. :install
  21. pkunzip -o -d tftd %1\mps\tftd
  22.  
  23. Rem Checking for errors
  24. if errorlevel 1 goto error2
  25.  
  26. goto end
  27.  
  28. :usage
  29. cls
  30. echo You must supply the DRIVE you wish to install the Terror From the 
  31. echo Deep demo to.
  32. echo EXAMPLE:  INSTALL C:
  33. goto END
  34.  
  35. :usage2
  36. cls
  37. echo The Terror From The Deep Demo Requires 4 Megabytes of Hard drive
  38. echo space to install. Drive %1 doesn't have enough space to install TFTD.
  39. echo Please free up some space on the %1 Drive and try again.
  40. goto END
  41.  
  42. :usage3
  43. cls
  44. echo This install must be run from the same DRIVE/DIRECTORY that the 
  45. echo Terror From the Deep Demo files are located in.  Please change to that
  46. echo DRIVE/DIRECTORY and run INSTALL again.
  47. goto END
  48.  
  49. :error1
  50. cls
  51. echo The install was unable to create the installation directory.
  52. echo This means that you do not have enough disk space or that you forgot
  53. echo to put a : on the drive letter to install to, or the installation
  54. echo directory already exists.  If the directory %1\MPS\TFTD already exists
  55. echo on your hard drive then use the -O command to overwrite the existing
  56. echo directory.
  57. echo EXAMPLE:  INSTALL C: -O
  58. if "%2" == "-o" goto install
  59. if "%2" == "-O" goto install
  60. if "%2" == "o" goto install
  61. if "%2" == "O" goto install
  62. goto END
  63.  
  64. :error2
  65. cls
  66. echo An Error has occured while installing the software, you may have
  67. echo a bad copy.  Please try the install again, if it fails then get
  68. echo another copy of this update.
  69. goto END
  70. :end
  71. cls
  72.  
  73. echo Installation Complete!
  74.  
  75.  
  76. cd\
  77.  
  78.  
  79. echo type TFTD to run the demonstrationĀ 
  80. echo .
  81. echo .
  82. echo .
  83. echo If installing this game has left you 
  84. echo at the DOS prompt. Reload the front
  85. echo by typing the PCG or MENU command.
  86. echo .
  87. echo .
  88.  
  89.