#!/bin/sh
# Startscript for a Kingpin dedicated Linuxserver written by [Lag]Area
#
# There are a few ways to run a kp-server under linux. Three of them are listed in the 
# following.  Just uncomment the the line of your choice (remove #). 

# Gamedirectory variable, change it if necessary
GAMEDIR='TM'

##############################################################################################
# 1. Run kp-server via screen (highly recommended)
#    Note:  screen has to be installed.
#    Usage: ./start_Kpded  To recover Kingpinconsole type "screen -r Kp" or, if u run only 
#           one Instance of Kp, just "screen -r"
#screen  -A -m -d -S Kp ./kpded + set game $GAMEDIR  + set port 31510 + exec server.cfg


##############################################################################################
# 2. Run kp-server via nohup (you should use this if you dont have screen installed)
#    nohup catches the kingpin-console-output and pipes it into a file usually called nohup.out
#    Usage: "./start_Kpded",  to stop the server type "skill kpded" 
# nohup ./kpded + set game $GAMEDIR + set port 31510 + exec server.cfg &


#############################################################################################
# 3. Run kp-server in console (recommended for debugging)
#
./kpded + set game $GAMEDIR + set port 31510 + exec server.cfg 

exit 0
