;;; CD to AACD root if run from elsewhere, e.g. AutoRun
cd >NIL: {VOL}
;;;
;;; Check argument - exit if Welcome has been run, otherwise ask
If {CHECK} EQ "YES"
Assign >NIL: AACD: EXISTS
If NOT WARN
Skip ABORT
Else
set init `:System/C/RequestChoice "Amiga Active CD" "Some assigns need to be made before we can proceed.*NYou can remove them later with the RemoveCD icon" "OK|Cancel"`
If $init EQ 0
Skip ABORT
EndIf
EndIf
EndIf
;;;
;;; Skip to HTML if Welcome has already been run
Assign >NIL: AACD: EXISTS
If NOT WARN
Skip HTML
EndIf
;;;
;;; Set up temporary assign
Assign AACDtmp: :
set ReqTitle Welcome to the Amiga Active CD
;;;
;;; Check for some system assigns
; MUI
Assign MUI: EXISTS >NIL:
If WARN
AACDtmp:System/C/RequestChoice >NIL: "`get ReqTitle`" "Some of the software on this CD requires MUI*NIf you use it regularly you should install MUI to your hard drive.*NThe installer is in the CDTools drawer of this CD" "I see"
Assign >NIL: MUI: AACDtmp:CDTools/MUI
Assign >NIL: LIBS: AACDtmp:CDTools/MUI/libs ADD
EndIf
; ClassAct
If NOT EXISTS LIBS:window.class
AACDtmp:System/C/RequestChoice >NIL: "`get ReqTitle`" "Some of the software on this CD requires ClassAct*NIf you use it regularly you should install ClassAct to your hard drive.*NThe installer is in the CDTools drawer of this CD" "I see"
EndIf
;;;
;;; Start arexx if not running
AACDtmp:System/rexxc/rx "address command" >NIL:
If WARN
AACDtmp:System/System/RexxMast >NIL:
Wait 3
EndIf
rx "call addlib('rexxsupport.library',0,-30,0)
;;;
;;; Make sure files needed by CD system are available
set edit `RequestChoice "Amigaactive CD" "AACD has a preferences program to specify*N the tools used to view/hear different types of files.*NWould you like to run it now?" "Yes|No"`
If $edit EQ 1
stack 16384
MuiRexx AACDPrefs port AACDPREFS
Else
RequestChoice >NIL: "Amiga Active CD" "You can run AACD preferences at any time.*NEither from its icon or from the Setup page of the documentation." "OK"
EndIf
EndIf
;;;
;;; Set assigns for programs on this CD and system drawers
Execute AACDtmp:CDTools/S/ThisCD
Assign >NIL: DEVS: AACDtmp:System/Devs ADD
Assign >NIL: Fonts: AACDtmp:System/Fonts ADD
Assign >NIL: Libs: AACDtmp:System/Libs ADD
Assign >NIL: L: AACDtmp:System/L ADD
Assign >NIL: S: AACDtmp:CDTools/S ADD
Assign >NIL: REXX: AACDtmp:CDTools/S ADD
Assign >NIL: LIBS: AACDtmp:System/Classes ADD
; Make environment variables defined on CD available to system
set RunNI `AACDtmp:System/C/RequestChoice "Amiga Active CD" "This CD is set up for use with NewIcons*NIf you do not run Newicons the icon*Nimages and layout may look strange.*N*NWould you like to run NewIcons now?" "Yes|No"`
If $RunNI EQ 1
Run <>NIL: AACDtmp:System/C/NewIcons
EndIf
EndIf
EndIf
EndIf
;;;
;;; Change temporary assign to permanent one
If {QUIET} NOT EQ "YES"
Run >NIL: RequestChoice >NIL: "`get ReqTitle`" "We have set up some assigns to run software from the CD.*N*NIf you wish to remove the CD from the drive, doubleclick the RemoveCD icon,*Notherwise the icon will stay on your Workbench." " OK "
Endif
Assign AACD: AACDtmp:
Assign AACDtmp:
;;;
;;; Do this if this is the first time this CD has been initialised
If `cd` GT $AACDlast
rx AACD:CDTools/S/UpdateIndices
setenv ENVARC:AACDNewsFlash 1
setenv AACDlast `cd`
copy ENV:AACDlast ENVARC: QUIET
EndIf
;;;
;;; Load HTML - using registered AWeb if available
LAB HTML
If {QUIET} EQ "YES"
If NOT EXISTS ENVARC:AACDNewsFlash
Skip END
EndIf
EndIf
set Browser AACD:AACD/Information/Browsers/AWeb3/AWebDemo