home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format 101 / af101b.adf / installers.lzx / Installers / CoreDesign / ChuckRock2 / Install-ChuckRock2 < prev    next >
Text File  |  2017-03-19  |  2KB  |  121 lines

  1. (set GameDir "ChuckRock2")
  2.  
  3. ;----------------------------
  4.  
  5. ;try to figure out a place where the user usually installs his games
  6. (if (exists "Games:" (noreq) )
  7.     (set @default-dest "Games:")
  8.     (if (exists "SYS:Games" (noreq) )
  9.         (set @default-dest "SYS:Games")
  10.         (if (exists "Work:Games" (noreq) )
  11.             (set @default-dest "Work:Games")
  12.             (if (exists "JEUX:" (noreq) )
  13.                (set @default-dest "JEUX:")
  14.                (set @default-dest "SYS:")
  15.             )
  16.         )
  17.     GameDir
  18.     )
  19. )
  20.  
  21. (set #game_ver
  22.     (askchoice
  23.         (prompt "Which version")
  24.         (help    @askoptions-help)
  25.         (choices
  26.            "CD-32 version"
  27.            "Floppy version"
  28.         )
  29.     )
  30. )
  31.  
  32. (set @default-dest
  33. (askdir
  34.     (prompt ("Where should %s installed ?\nA drawer \"%s\" will automatically created." @app-name @app-name))
  35.     (help @askdir-help)
  36.     (default @default-dest)
  37.     (disk)
  38. )
  39. )
  40.  
  41. (set #dest (tackon @default-dest @app-name))
  42.  
  43.  
  44. (makedir #dest
  45.     (help @makedir-help)
  46.     (infos)
  47. )
  48.  
  49. ;----------------------------
  50.  
  51. (copyfiles
  52.     (help @copyfiles-help)
  53.     (source "Chuck2HD")
  54.     (dest #dest)
  55.     (infos)
  56. )
  57.  
  58. (copyfiles
  59.     (help @copyfiles-help)
  60.     (source "chuck2hd.readme")
  61.     (dest #dest)
  62.     (infos)
  63. )
  64.  
  65.  
  66. (if (= #game_ver 1)
  67.     (
  68.  
  69. (set #CI_unit
  70.     (askchoice
  71.         (prompt "From which disk unit do you want\nto install the game")
  72.         (help    @askoptions-help)
  73.         (choices
  74.            "DF0:"
  75.            "DF1:"
  76.            "DF2:"
  77.            "DF3:"
  78.         )
  79.     )
  80. )
  81.  
  82. (set #CI_drive ("DF%ld:" #CI_unit))
  83.  
  84.  
  85.     (message ("\nInsert %s disk 1 into drive %s !" @app-name #CI_drive))
  86.     (if
  87.         (= 0 (run ("disk2file %ld \"%s/ChuckRock2.disk1\" SKIPROB >con:///1000//CLOSE/WAIT" #CI_unit #dest )))
  88.         ("")
  89.         (abort "\"disk2file\" must be in your PATH !")
  90.     )
  91.  
  92.     (message ("\nInsert %s disk 2 into drive %s !" @app-name #CI_drive))
  93.     (if
  94.         (= 0 (run ("disk2file %ld \"%s/ChuckRock2.disk2\" >con:///1000//CLOSE/WAIT" #CI_unit #dest )))
  95.         ("")
  96.         (abort "\"disk2file\" must be in your PATH !")
  97.     )
  98.  
  99. )
  100.  
  101. (if (= #game_ver 0)
  102.     (
  103.     (message ("\nInsert %s CD-ROM into any drive" @app-name))
  104.  
  105.         (copyfiles (source "CHUCK_ROCK_2:soc1")
  106.                    (dest #dest)
  107.            (newname "ChuckRock2.disk1")
  108.         )
  109.  
  110.         (copyfiles (source "CHUCK_ROCK_2:soc2")
  111.                    (dest #dest)
  112.            (newname "ChuckRock2.disk2")
  113.         )
  114.  
  115.     )
  116.     )
  117. )
  118.  
  119. (exit)
  120.  
  121.