Kaynağa Gözat

Merge pull request #103 from Scarsz/patch-1

Add native workshop support
Daniel Gibbs 12 yıl önce
ebeveyn
işleme
8110e0933d
1 değiştirilmiş dosya ile 7 ekleme ve 2 silme
  1. 7 2
      GarrysMod/gmodserver

+ 7 - 2
GarrysMod/gmodserver

@@ -16,6 +16,11 @@ email="email@example.com"
 steamuser="anonymous"
 steampass=""
 
+# Workshop Variables
+# http://wiki.garrysmod.com/page/Workshop_for_Dedicated_Servers
+workshopauth=""
+workshopcollectionid=""
+
 # Start Variables
 defaultmap="gm_construct"
 maxplayers="16"
@@ -26,7 +31,7 @@ ip="0.0.0.0"
 
 # https://developer.valvesoftware.com/wiki/Command_Line_Options#Source_Dedicated_Server
 fn_parms(){
-parms="-game garrysmod -strictportbind -ip ${ip} -port ${port} +clientport ${clientport} +tv_port ${sourcetvport} +map ${defaultmap} +servercfgfile ${servercfg} -maxplayers ${maxplayers}"
+parms="-game garrysmod -strictportbind -ip ${ip} -port ${port} +host_workshop_collection ${workshopcollectionid} -authkey {workshopauth} +clientport ${clientport} +tv_port ${sourcetvport} +map ${defaultmap} +servercfgfile ${servercfg} -maxplayers ${maxplayers}"
 }
 
 #### Advanced Variables ####
@@ -863,4 +868,4 @@ case "$1" in
 	echo "Usage: $0 {start|stop|restart|update|update-restart|validate|validate-restart|monitor|email-test|details|backup|console|debug|install}"
 	exit 1;;
 esac
-exit
+exit