#!/bin/sh
# Wrapper script to launch different Roborumble competitions
# Please adjust your configuration scripts in your roborumble directory before
# launching the competition
set -e

VER=1.9.2.5
WORKING_DIRECTORY=~/.local/share/robocode/${VER}

# Change this value as needed
# Possible values are
# - roborumble (default)
# - meleerumble
# - teamrumble
# - twinduel
COMPETITION=roborumble

cd ${WORKING_DIRECTORY}
printf 'CWD: '
pwd

java \
    -Xmx512M \
    -cp /usr/share/java/robocode.jar:/usr/share/java/roborumble.jar:/usr/share/java/codesize.jar \
    roborumble.RoboRumbleAtHome \
    ${WORKING_DIRECTORY}/roborumble/${COMPETITION}.txt \
    "$@"
