echo -text "Installing PaintWare Base w/Gun Ctrl"

invoke -entry pwinst_init

text -filename $BOOTPATH/pwinst.$LANG -package 0
text -filename $BOOTPATH/pwdata.eng -package 0
text -filename $BOOTPATH/rlpw.eng -package 0
text -filename $BOOTPATH/pwmmc.$LANG -package 0

config -filename $BOOTPATH/teach_po.cfg -domain EIO
#config -filename $BOOTPATH/pw_eio.cfg -domain EIO
config -filename $BOOTPATH/pw_sys.cfg -domain SYS  -internal
config -filename $BOOTPATH/rlpw.cfg -domain MMC -internal
config -filename $BOOTPATH/pwmmc.cfg -domain MMC

#Files specific for Gun control
setvar -var 11 -value 10
config -filename $BOOTPATH/pwinst.cfg -domain MMC -internal
setvar -var 10 -value 0
getkey -id "NuAppl" -var 10 -strvar $ANSWER -errlabel NEXT
goto -label END
#NEXT
config -filename $BOOTPATH/pwa1ch1.cfg -domain PROC
setvar -var 10 -value 0
getkey -id "IrbSelect" -var 10 -strvar $ANSWER -errlabel EIOPW
ifstr -strvar $ANSWER -value "IRB540_02_T00F11B21V21m1H21m1" -label PWACA
ifstr -strvar $ANSWER -value "IRB540_12_T00F11B21V21m1H21m1" -label PWACA
ifstr -strvar $ANSWER -value "IRB540_15_T00F11B21V21m1H21m1" -label PWACA
ifstr -strvar $ANSWER -value "IRB540_05_T00F11B21V21m2H21m1" -label PWACA
#EIOPW
config -filename $BOOTPATH/eiopw.cfg -domain EIO -replace
goto -label NEXT
#PWACA
config -filename $BOOTPATH/eio540pw.cfg -domain EIO -replace
#NEXT
#END
append -from $BOOTPATH/startup.cmd -to option.cmd

echo -text "... done"

