;ProTracker Pro INSTALLATION SCRIPT © TEC DESIGN
;VER: $1.2e 22.05.1996 (LHA)

(set @app-name "ProTracker Pro") 
(set @language "english")
(set @abort-button "Abort Installation")
(set @error-msg "Error!")
(set @pretend 0)
(set @special-msg "Large Error!")
(set @user-level 2)

(welcome "Welcome to the Protracker Pro V3.55 Installation.\nNote: you MUST have booted from your hard disk!")
(set Ok 0)
(complete 0)

(set pt_dir (getassign "ProTracker" "a")) 
  (
     (set pt_dir
        (askdir
           (prompt
              "Please choose a path who Protracker should\n"
              "be installed.\n"
               "A new drawer named 'Protracker' would be\n "
              "created.\n"
           (help
              "Choose path for Protracker main file and the guide\n")
           (default "SYS:"))
        )
     )
     (set pt_dir (tackon pt_dir "ProTracker"))

     ;CREATE PT DRAWER
     (if (<> (exists pt_dir) 2) (makedir pt_dir (infos)))

  )
(copyfiles
   (prompt "Copying base files ...")
   (help "dummy")
   (source "Main/")
   (dest pt_dir)
   (pattern "#?")
   (safe)
   (infos)
   (confirm)
   (optional nofail askuser)
)
(complete 40)

;copying of the help data file in s:

(copyfiles
   (prompt "Copying helpfile")
   (help "dummy")
   (source "Data/")
   (dest "S:")
   (pattern "pt.help")
   (safe)
   (infos)
   (confirm)
   (optional nofail askuser)
)
(complete 50)

(copyfiles
   (prompt "Please choose your locale Keyboard driver ...\nActually only this german driver aviable!\nSkip this part if your native language is NOT german.\n")
   (help "actually only german driver aviable")
   (source "Data/")
   (dest "S:")
   (pattern "pt.keymap#?")
   (safe)
   (infos)
   (confirm)
   (optional nofail askuser)
)
(complete 60)

(copyfiles
   (prompt "Install of default configuration files...\n\nWarning: Since V3.55 the old configs not more usuable!.\n")
   (help "usefull standart configurations for quickstarting with Protracker Pro.")
   (source "Data/")
   (dest "S:")
   (pattern "pt.config#?")
   (safe)
   (infos)
   (confirm)
   (optional nofail askuser)
)
(complete 70)


;if not anythere install ST-00 standarts
(set st_dir (getassign "ST-00" "a")) 
  (
     (set st_dir
        (askdir
           (prompt
              "Please choose a path who Installer should made an\n"
              "ST-00 drawer. Protracker need this for his Sound Files\n"
              "with an logical Assign to ST-00: If already exists,\n"
              "nothings will be overwritten. Only the dirs will\n "
              "be created if not aleady aviable.\n"
           (help
              "Choose path for ST-00 assignment\n")
           (default pt_dir))
        )
     )
     (set st_dir (tackon st_dir "ST-00"))

     ;CREATE ST DRAWER
     (if (<> (exists st_dir) 2) (makedir st_dir (infos)))

     ;create ST subdrawerd
     (set md_dir (tackon st_dir "modules"))
     (if (<> (exists md_dir) 2) (makedir md_dir (infos)))

     (set so_dir (tackon st_dir "songs"))
     (if (<> (exists so_dir) 2) (makedir so_dir (infos)))

     (set sa_dir (tackon st_dir "samples"))
     (if (<> (exists sa_dir) 2) (makedir sa_dir (infos)))

     (set pa_dir (tackon st_dir "patterns"))
     (if (<> (exists pa_dir) 2) (makedir pa_dir (infos)))

     (set ins_dir (tackon st_dir "instruments"))
     (if (<> (exists ins_dir) 2) (makedir ins_dir (infos)))

     (set exe_dir (tackon st_dir "executables"))
     (if (<> (exists exe_dir) 2) (makedir exe_dir (infos)))

  )
(complete 90)
(set start-lines (cat "assign ST-00: " st_dir))
(startup @app-name (prompt "\nThe following lines will be added to "
                               "your user-startup:\nassign ST-00: "
                               st_dir "\n")
                       (command start-lines)
(help "Protracker needs an assign named ST-00 who most MODS/samples are installed")
)
;installation complete

(complete 100)
(exit "Installation of Protracker complete.If you are an programmer, please take a look in the drawer 'source' ...\n\n\n\nHave Fun!\n\n")
