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.
36 lines
1.0 KiB
36 lines
1.0 KiB
#!/bin/bash
|
|
|
|
#Configuration
|
|
conf_file="valheim-server.ini"
|
|
|
|
# No need to change anything under this line
|
|
|
|
# source config parser
|
|
. ./lib_ini.sh
|
|
|
|
server_path=$(ini_read "$conf_file" "server" "srvpath")
|
|
server_name=$(ini_read "$conf_file" "server" "srvname")
|
|
server_pass=$(ini_read "$conf_file" "server" "srvpass")
|
|
server_moded=$(ini_read "$conf_file" "server" "srvmoded")
|
|
|
|
cd "$server_path"
|
|
|
|
if [[ "$server_moded" == "true" ]]; then
|
|
# source modding engine
|
|
. ./bepinex_conf.inc
|
|
fi
|
|
|
|
# standard startup routine
|
|
export templdpath=$LD_LIBRARY_PATH
|
|
export LD_LIBRARY_PATH=./linux64:$LD_LIBRARY_PATH
|
|
export SteamAppID=892970
|
|
|
|
# Creating dirs
|
|
mkdir -p "$server_path/savedir"
|
|
mkdir -p "$server_path/logs"
|
|
|
|
echo "Starting server..."
|
|
./valheim_server.x86_64 -name "$server_name" -port 2456 -nographics -batchmode -world "$server_name" -password "$server_pass" -public 1 -crossplay -savedir $server_path/savedir -logFile $server_path/logs/valheim.log -backups 8 -modifier raids none -modifier DeathPenalty casual -modifier Combat veryeasy
|
|
export LD_LIBRARY_PATH=$templdpath
|
|
|