echo off
cls
if not exist duke3d.exe goto error

:menu
cls
echo.
echo -------------------------------------------------------------------------------
echo         ========- Stargate SG-1 TC: In the hands of a serpent -========           
echo -------------------------------------------------------------------------------
echo.
echo.
echo.
echo                       A)     Single Player SG-1
echo                       B)     GateMatch (DukeMatch)
echo                       C)     View Readme
echo                       D)     Exit
echo.
echo.
echo.
echo.
echo.

if exist sg.on echo STARGATE SG-1 - INSTALLED
if exist sg.off echo STARGATE SG-1 - NOT INSTALLED

choice /c:abcd
if errorlevel 4 goto exit
if errorlevel 3 goto readme
if errorlevel 2 goto dm
if errorlevel 1 goto si

:error
echo.
echo You must be in the wrong directory!
echo.
goto end

:exit
goto end

:readme
echo ----------------------------------------------------------------------
echo .  S       T       A       R               G       A       T       E .
echo .                                                                    .
echo .                      In the Hands of the Serpent                   .
echo ----------------------------------------------------------------------
echo .              3 Whole new episodes and art for Duke3D!              .
echo .                                                                    .
echo .   for Duke Nukem 3D                                                .
echo .                    by David G. Paul                                .
echo .                                                                    .
echo .   After the death of Ra, the Gh'oalds have been angered and have   .
echo . prepared to attack earth. You as the sole defender of the US must  .
echo . use the Stargate to find evrything you need before challenging the .
echo . Gh'oald aboard their attack ships heading for earth. The Jaffa     .
echo . have been scattered on planets like Chu'lak, and Abydos to try     .
echo . and thwart your plans. Stop them or die trying......               .
echo ----------------------------------------------------------------------
pause
Loading DATA File...
type sg1.txt |more
cls
goto menu

:p2
echo.
echo STARGATE SG-1 IS NOT INSTALLED !
echo.
pause
goto menu

:si
if exist goto si1
rename *.art *.sga
rename *.wav *.sgw
rename *.voc *.sgv
rename *.con *.sgc
move maps\tc\sg-1\*.* ../../../
rename sg1.off sg1.on
:si1
duke3d
goto menu

:dm
if exist sg1.on goto dm1
rename *.art *.sga
rename *.wav *.sgw
rename *.voc *.sgv
rename *.con *.sgc
move maps\tc\sg-1\*.* ../../../
rename sg1.off sg1.on
:dm1
cd\duke3d
duke3d -net
goto menu

:end
echo.	Do you wish to return files to maps\tc\sg-1 directory? (Y/N)
choice
if errorlevel 2 goto exit
if errorlevel 1 goto move
goto end

:exit
echo.
echo Stargate SG-1 TC: In the hands of a serpent
echo by David G. Paul (Amlar) of New Earth Publications
echo.
echo E-mail me at: amlar@newearth3.freeserve.co.uk
echo Tech Support @ techsupport@newearth3.freeserve.co.uk
echo Visit my site at: http://www.newearth3.freeserve.co.uk
echo.                  http://www.newearth3/freeserve.co.uk/duke3d
echo.		     & http://www.sg1tc.freeserve.co.uk

:move
move base.map maps\tc\sg-1
move chulak.map maps\tc\sg-1
move abydos.map maps\tc\sg-1
move s4nox.map maps\tc\sg-1
move *.voc maps\tc\sg-1
move sg1*.mid maps\tc\sg-1
move seaq*.mid maps\tc\sg-1
move stargate.mid maps\tc\sg-1
move base.txt maps\tc\sg-1
move chulak.txt maps\tc\sg-1
move abydos.txt maps\tc\sg-1
move s4nox.txt maps\tc\sg-1
move *.wav maps\tc\sg-1
move *.art maps\tc\sg-1
rename sg1.on sg1.off
rename *.sga *.art
rename *.sgv *.voc
rename *.sgw *.wav
rename *.sgc *.con
echo. Files Finished
goto exit