
alles was dazu gehoert drauf , via ftp :
einzige was ich noch wissen muss , wo schreib mann die verdammte
+set fs_game etpub +set com_hunkmegs 32 +exec server.cfg
rein ,

Danke an alle

Code: Alles auswählen
#!/bin/sh
### BEGIN INIT INFO
# Provides: et-server
# Required-Start: $local_fs
# Required-Stop: $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Enemy-Territory Server
# Description: This script control the Enemy-Territory Server
### END INIT INFO
SERVER_CONFIG="/etc/et-server.conf"
case "$1" in
'start')
if [ -r $SERVER_PID ]; then
echo "${SERVER_BIN} is actually running!"
exit;
else
echo -n "starting ET-Server... "
rm -f $SERVER_RUN
cd $SERVER_ROOT
if [ ! -z $SERVER_MODDIR ]; then
SERVER_OPTIONS=$SERVER_OPTIONS\ +set\ fs_game\ $SERVER_MODDIR
fi
SERVER_OPTIONS=$SERVER_OPTIONS\ +exec\ server.cfg
start-stop-daemon --background --start --make-pidfile --pidfile $SERVER_PID --exec $SERVER_BIN -- $SERVER_OPTIONS
sleep 2
if [ -r $SERVER_PID ] ; then
echo "done"
else
echo "failed"
fi
fi
;;
'stop')
echo -n "stopping ET-Server... "
if [ -r $SERVER_PID ] ; then
start-stop-daemon --stop --pidfile $SERVER_PID && rm -f $SERVER_PID
echo "done"
else
echo "Could not find a PID for ${SERVER_BIN}!"
fi
;;
'restart')
echo -n "stopping ET-Server... "
if [ -r $SERVER_PID ] ; then
start-stop-daemon --stop --pidfile $SERVER_PID && rm -f $SERVER_PID
echo "done"
fi
sleep 2
$0 start
;;
*)
echo "usage $0 start | stop | restart"
esac
Code: Alles auswählen
# the FULL PATH to the server binary.
#this is used by /sbin/pidof in determining if the server is running.
SERVER_BIN="/usr/local/games/enemy-territory/etded.x86"
# the location of a file that the PID of the server binary should be stored in.
SERVER_PID="/var/run/etded.x86.pid"
# the chroot 'root' directory where your game server is installed.
SERVER_ROOT="/usr/local/games/enemy-territory"
# additional options that should be passed to the game server command line.
# for example, "+set ttycon 0 +exec server.cfg +set net_ip 127.0.0.1"
SERVER_OPTIONS="+set com_hunkmegs 32 +set ttycon 0 +set fs_homepath /home/et/.etwolf +set sv_punkbuster 1"
#the name of the directory for the modification.
SERVER_MODDIR="etpro"
Code: Alles auswählen
rcon <rconpass> set fs_game etpub
rcon <rconpass> set com_hunkmegs 32
rcon <rconpass> killserver