; $VER: XTR Stuff installer V1.25 by Barry Beukhof
;
; Because A lot of people now use LZX instead of
; LHA I've decided to include a LZX option.
;
; !! AMIGA RULES !!


assign >nil: xt: XTR_TRACKS/

setenv arch `requestchoice "Question ?" "Which Archiver *nDo you want to use*nto unarchive Files ?" "Lha" "Lzx"`

setenv dir `requestfile Drawer "Games:" Title "Select your XTR directory" noicons drawersonly`

cd $dir


if $arch eq 0
skip LZX
endif



;The LHA VERSION

if exists xt:layouts.lha
cd layouts/
lha >nil: x xt:layouts.lha 
endif

if exists xt:tracks.lha
cd /tracks/
lha >nil: x xt:tracks.lha  
endif

if exists xt:worlds.lha
cd /worlds/
lha >nil: x xt:worlds.lha  
endif

if exists xt:objects.lha
cd /objects/
lha >nil: x xt:objects.lha 
endif

skip QUIT



; THE LZX VERSION

lab LZX

if exists xt:layouts.lha
cd layouts/
lzx >nil: x xt:layouts.lha
endif

if exists xt:tracks.lha
cd /tracks/
lzx >nil: x xt:tracks.lha
endif

if exists xt:worlds.lha
cd /worlds/
lzx >nil: x xt:worlds.lha  
endif

if exists xt:objects.lha
cd /objects/
lzx >nil: x xt:objects.lha 
endif



; THE END

lab QUIT

requestchoice >nil: "Barry Says" "Tracks have *nbeen installed" "Continue"

endcli