@echo off
rem Usage: TeamDbg         -> starts team XRays
rem        TeamDbg 2       -> starts team Badgers
rem        TeamDbg xxxyyy  -> starts team xxxyyy

if %1a == a goto firstTeam
if %1 == 2 goto secondTeam

set name=%1
goto run

:firstTeam
set name=XRays
goto run

:secondTeam
set name=Badgers
goto run

:run
REM start ..\rcssserver.exe
REM pause
start Output\GoalieRelease\Goalie -t 11 -a -g -n %name%

REM start Output\GoalieRelease\Goalie -t 11 -a -g -n TiDruhi
REM goto exit

echo Wait until goalie connects to server
rem pause

start Output\CoachRelease\Coach -t 11 -a -n %name% -t 4 -l Logo\

REM start Output\PlayerRelease\Player -t 11 -a -n TiDruhi
delay 200
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100

start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%
delay 100
start Output\PlayerRelease\Player -t 11 -a -n %name%

:exit
