;
; ARENA Installation script
;
; Copyright © 1995 S. Craig Taylor. All rights reserved.
;
; $ID Install 1.4 31/10/95
;
; Languages available:
;   English (default)
;
; =======================================================================
;   Set up localized strings
; =======================================================================

;
; ===== English
;
(set #welcome "        Welcome to the ARENA  installation\n\n           Copyright © 1995 S.Craig Taylor.\n                 All rights reserved.\n")
(set #dir_prompt "Where should ARENA be installed? A drawer named `ARENA' will be created there. If you're updating from a previous version, select the directory containing the ARENA drawer.")
(set #addcmds "The following instructions will be added to your \"S:User-Startup\" file so that your system will be properly configured to use ARENA.\n\nAssign ARENA %s")
(set #addhelp "This will add some commands to your S:User-Startup file to allow the correct operation of ARENA.")
(set #thanks "\nThank you for playing ARENA.\n\n")
(set #userstartup "; Executive installation was aborted.")
(set #abort_remove "Installation aborted.")
;

; =======================================================================
;   Begin installation
; =======================================================================

(welcome #welcome)

(complete 0)

; ===== cancel the assign in case it already exists
(makeassign "ARENADEST" (safe))

(set ARENADEST
    (tackon
        (askdir
            (prompt #dir_prompt)
            (help #dir_help @askdir-help)
            (default @default-dest)
        )
        "ARENA"
    )
)

(makeassign "ARENADEST"
	(pathonly ARENADEST)
	(safe)
)

; ===== Tells installer where ARENA shoud  be installed
(set @default-dest ARENADEST)

; ===== Copy Files
(makedir "ARENADEST:ARENA")
(makedir "ARENADEST:ARENA/ARENAS")
(run "copy ARENAS.INFO ARENADEST:ARENA.INFO")
(complete 1)
(run "copy ARENAS.INFO ARENADEST:ARENA")
(complete 2)
(run "copy ARENA ARENADEST:ARENA")
(complete 30)
(run "copy ARENA.INFO ARENADEST:ARENA")
(complete 31)
(run "copy ARENATITLE32.ABK ARENADEST:ARENA")
(complete 35)
(run "copy ARENA_TITLE4.ABK ARENADEST:ARENA")
(complete 40)
(run "copy EXPLODE2.ABK ARENADEST:ARENA")
(complete 45)
(run "copy FACES2.ABK ARENADEST:ARENA")
(complete 50)
(run "copy INTO_THE_ARENA2.ABK ARENADEST:ARENA")
(complete 55)
(run "copy LPICONS2.ABK ARENADEST:ARENA")
(complete 65)
(run "copy LPSOUNDS2.ABK ARENADEST:ARENA")
(complete 70)
(run "copy ARENAS/#? ARENADEST:ARENA/ARENAS")
(complete 90)
(if (not (exists "SYS:FONTS/2001" (noreq)))
	(Makedir "SYS:FONTS/2001")
)
(run "COPY FONTS/2001/8 SYS:FONTS/2001")
(run "COPY FONTS/2001.font SYS:FONTS")
(complete 95)
;
(if (not (exists "SYS:FONTS/ARENA" (noreq)))
	(Makedir "SYS:FONTS/ARENA")
)
(run "COPY FONTS/ARENA.font SYS:FONTS")
(run "COPY FONTS/ARENA/13 SYS:FONTS/ARENA")
(complete 99)

; ===== Add Assign command to s:user-startup
(startup "ARENA"
	(prompt (#addcmds ARENADEST ARENADEST))
	(help #addhelp @startup-help)
	(command ("ASSIGN ARENA: %s" ARENADEST))
)

(complete 100)
;(makeASSIGN ARENA: "ARENADEST")
(makeASSIGN "ARENA: ARENADEST")
(exit #thanks)
