lgsm local mirror
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

33 lines
1.0 KiB

#!/bin/bash
# LGSM fn_serverconfig function
# Author: Daniel Gibbs
# Website: http://danielgibbs.co.uk
# Version: 291114
echo "Downloading lgsm-default.cfg"
echo "================================="
sleep 1
cd "${servercfgdir}"
wget --no-check-certificate -nv -N https://raw.githubusercontent.com/dgibbs64/linuxgameservers/master/CounterStrikeSource/cfg/lgsm-config.cfg
echo ""
echo "Loading Configs"
echo "================================="
sleep 1
echo "creating ${servicename}.cfg config file."
cp -v lgsm-default.cfg ${servercfgfullpath}
sleep 1
echo "creating server.cfg."
touch "${defaultcfg}"
sleep 1
echo "creating redirect."
echo "server.cfg > ${servercfg}."
echo "exec ${servercfg}" > "${defaultcfg}"
sleep 1
echo ""
echo "Configuring ${gamename} Server"
echo "================================="
sleep 1
read -p "Enter server name: " servername
read -p "Enter rcon password: " rconpass
sed -i "s/\"hostname\"/\"${servername}\"/g" ${servercfgfullpath}
sed -i "s/\"rconpassword\"/\"${rconpass}\"/g" ${servercfgfullpath}