Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions sniper/etc/entry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,16 @@ if [[ ! -z $CS2_BOT_QUOTA_MODE ]] ; then
sed -i "s/bot_quota_mode.*/bot_quota_mode ${CS2_BOT_QUOTA_MODE}/" "${STEAMAPPDIR}"/game/csgo/cfg/*
fi

# Rewrite tv_delay in gamemode_competitive.cfg (because it supersedes the value in server.cfg)
if [[ -n "${TV_DELAY}" ]]; then
COMPETITIVE_CFG="${STEAMAPPDIR}/game/csgo/cfg/gamemode_competitive.cfg"
if grep -q "^tv_delay" "$COMPETITIVE_CFG"; then
sed -ri "s/^tv_delay[[:space:]]+.*/tv_delay ${TV_DELAY}/" "$COMPETITIVE_CFG"
else
echo "tv_delay ${TV_DELAY}" >> "$COMPETITIVE_CFG"
fi
fi

# Switch to server directory
cd "${STEAMAPPDIR}/game/"

Expand Down
Loading