diff --git a/unturned.kvp b/unturned.kvp new file mode 100644 index 0000000..a996a8f --- /dev/null +++ b/unturned.kvp @@ -0,0 +1,72 @@ +Meta.DisplayName=Unturned +Meta.Description=Unturned 3 Dedicated Server +Meta.OS=Windows, Linux +Meta.Author=Greelan +Meta.URL=https://smartlydressedgames.com/#unturned +Meta.DisplayImageSource=url:https://cdn.cloudflare.steamstatic.com/steam/apps/304930/library_hero.jpg?t=1613683705 +Meta.EndpointURIFormat=steam://connect/{ip}/{GenericModule.App.ApplicationPort1} +Meta.ConfigManifest=unturnedconfig.json +Meta.MetaConfigManifest=unturnedmetaconfig.json +Meta.ConfigRoot=unturned.kvp +Meta.MinAMPVersion=2.3.2.0 +Meta.SpecificDockerImage= +Meta.Prerequsites=[] +App.DisplayName=Unturned +App.RootDir=./U3DS/ +App.BaseDirectory=./U3DS/1110390/ +App.ExecutableWin=1110390\Unturned.exe +App.ExecutableLinux=1110390/Unturned_Headless.x86_64 +App.WorkingDir=1110390 +App.LinuxCommandLineArgs= +App.WindowsCommandLineArgs= +App.CommandLineArgs={{$PlatformArgs}} -batchmode -nographics +{{ServerType}}/{{ServerName}} {{$FormattedArgs}} +App.AppSettings={} +App.EnvironmentVariables={"LD_LIBRARY_PATH":"./linux64:%LD_LIBRARY_PATH%:./Unturned_Headless_Data/Plugins/x86_64/","SteamAppId":"304930"} +App.CommandLineParameterFormat=-{0}/{1} +App.CommandLineParameterDelimiter= +App.ExitMethod=String +App.ExitTimeout=30 +App.ExitString=shutdown +App.ExitFile=app_exit.lck +App.HasWriteableConsole=True +App.HasReadableConsole=True +App.SupportsLiveSettingsChanges=False +App.LiveSettingChangeCommandFormat=set {0} "{1}" +App.ApplicationIPBinding=0.0.0.0 +App.ApplicationPort1=27015 +App.ApplicationPort2=27016 +App.ApplicationPort3=0 +App.RemoteAdminPort=27017 +App.MaxUsers=10 +App.UseRandomAdminPassword=False +App.RemoteAdminPassword=Password123 +App.AdminMethod=TelnetRCON +App.RCONConnectDelaySeconds=5 +App.RCONConnectRetrySeconds=5 +App.UpdateSources=[{"UpdateStageName":"SteamCMD Download","UpdateSourcePlatform":"All","UpdateSource":"SteamCMD","UpdateSourceData":"1110390"},{"UpdateStageName":"Main Config File Download","UpdateSourcePlatform":"All","UpdateSource":"FetchURL","UpdateSourceData":"https://raw.githubusercontent.com/CubeCoders/AMPTemplates/main/unturnedconfigfile.dat","UpdateSourceTarget":"../","OverwriteExistingFiles":true},{"UpdateStageName":"Workshop Config File Download","UpdateSourcePlatform":"All","UpdateSource":"FetchURL","UpdateSourceData":"https://raw.githubusercontent.com/CubeCoders/AMPTemplates/main/unturnedworkshopconfig.json","UpdateSourceTarget":"../","OverwriteExistingFiles":true},{"UpdateStageName":"Config Directory Creation","UpdateSourcePlatform":"All","UpdateSource":"CreateDirectory","UpdateSourceArgs":"./U3DS/1110390/Servers/{{ServerName}}/Server"},{"UpdateStageName":"Config File Copy","UpdateSourcePlatform":"All","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Servers/{{ServerName}}/Server/Commands.dat","UpdateSourceArgs":"./unturnedconfigfile.dat","OverwriteExistingFiles":false},{"UpdateStageName":"Rocket Directory Creation","UpdateSourcePlatform":"All","UpdateSource":"CreateDirectory","UpdateSourceArgs":"./U3DS/1110390/Modules/Rocket.Unturned"},{"UpdateStageName":"First Rocket File Copy","UpdateSourcePlatform":"All","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Modules/Rocket.Unturned/English.dat","UpdateSourceArgs":"./U3DS/1110390/Extras/Rocket.Unturned/English.dat","OverwriteExistingFiles":true},{"UpdateStageName":"Second Rocket File Copy","UpdateSourcePlatform":"All","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Modules/Rocket.Unturned/Rocket.API.dll","UpdateSourceArgs":"./U3DS/1110390/Extras/Rocket.Unturned/Rocket.API.dll","OverwriteExistingFiles":true},{"UpdateStageName":"Third Rocket File Copy","UpdateSourcePlatform":"All","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Modules/Rocket.Unturned/Rocket.Core.dll","UpdateSourceArgs":"./U3DS/1110390/Extras/Rocket.Unturned/Rocket.Core.dll","OverwriteExistingFiles":true},{"UpdateStageName":"Fourth Rocket File Copy","UpdateSourcePlatform":"All","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Modules/Rocket.Unturned/Rocket.Unturned.dll","UpdateSourceArgs":"./U3DS/1110390/Extras/Rocket.Unturned/Rocket.Unturned.dll","OverwriteExistingFiles":true},{"UpdateStageName":"Fifth Rocket File Copy","UpdateSourcePlatform":"All","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Modules/Rocket.Unturned/Rocket.Unturned.module","UpdateSourceArgs":"./U3DS/1110390/Extras/Rocket.Unturned/Rocket.Unturned.module","OverwriteExistingFiles":true},{"UpdateStageName":"Steam Directory Creation","UpdateSourcePlatform":"Linux","UpdateSource":"CreateDirectory","UpdateSourceArgs":"./U3DS/1110390/Unturned_Headless_Data/Plugins/x86_64"},{"UpdateStageName":"Steamclient Copy","UpdateSourcePlatform":"Linux","UpdateSource":"CopyFilePath","UpdateSourceData":"./U3DS/1110390/Unturned_Headless_Data/Plugins/x86_64/steamclient.so","UpdateSourceArgs":"./U3DS/1110390/linux64/steamclient.so","OverwriteExistingFiles":true}] +App.Compatibility=None +App.SteamUpdateAnonymousLogin=True +App.SteamForceLoginPrompt=False +App.RapidStartup=False +App.SupportsUniversalSleep=False +App.UniversalSleepApplicationUDPPort=27015 +App.UniversalSleepSteamQueryPort=27016 +App.WakeupMode=Any +App.ApplicationReadyMode=RegexMatch +App.TemplateMatchRegex={{(\$?[\w]+)}} +Console.FilterMatchRegex= +Console.FilterMatchReplacement= +Console.ThrowawayMessageRegex=^(WARNING|ERROR): Shader.+$ +Console.AppReadyRegex=^Loading level: 100%$ +Console.UserJoinRegex=^Connecting: PlayerID: (?.+?) Name: (?.+?) Character: (?.+?)$ +Console.UserLeaveRegex=^Disconnecting: PlayerID: (?.+?) Name: (?.+?) Character: (?.+?)$ +Console.UserChatRegex=^\[(?:World|Area|Group)\] (?.+?) \[(?.+?)\]: "(?.+)"$ +Console.UpdateAvailableRegex=^\[\d\d:\d\d:\d\d\] \[INFO\] A new server update is available! v[\d\.]+.$ +Console.SuppressLogAtStart=False +Console.ActivateLogRegex= +Console.UserActions={} +Limits.SleepMode=True +Limits.SleepOnStart=False +Limits.SleepDelayMinutes=5 +Limits.DozeDelay=2 +Limits.AutoRetryCount=5 \ No newline at end of file diff --git a/unturnedconfig.json b/unturnedconfig.json new file mode 100644 index 0000000..32ba672 --- /dev/null +++ b/unturnedconfig.json @@ -0,0 +1,283 @@ +[ + { + "DisplayName": "Server Port", + "Category": "Server Settings", + "Description": "", + "Keywords": "", + "FieldName": "$ApplicationPort1", + "InputType": "number", + "IsFlagArgument": false, + "Hidden": true, + "ParamFieldName": "Port", + "IncludeInCommandLine": false, + "DefaultValue": "27015" + }, + { + "DisplayName": "Enable RCON", + "Category": "Server Settings", + "Description": "", + "Keywords": "", + "FieldName": "RCONEnabled", + "InputType": "number", + "IsFlagArgument": false, + "Hidden": true, + "ParamFieldName": "/RocketSettings/RCON/@Enabled", + "IncludeInCommandLine": false, + "DefaultValue": "true" + }, + { + "DisplayName": "RCON Port", + "Category": "Server Settings", + "Description": "", + "Keywords": "", + "FieldName": "$RemoteAdminPort", + "InputType": "number", + "IsFlagArgument": false, + "Hidden": true, + "ParamFieldName": "/RocketSettings/RCON/@Port", + "IncludeInCommandLine": false, + "DefaultValue": "27017" + }, + { + "DisplayName": "Server Name", + "Category": "Server Settings", + "Description": "WARNING: You MUST do first-time server setup (update the server and start and stop it once) after changing the name for correct configuration", + "Keywords": "name", + "FieldName": "ServerName", + "InputType": "text", + "IsFlagArgument": false, + "ParamFieldName": "", + "IncludeInCommandLine": false, + "DefaultValue": "UnturnedServer" + }, + { + "DisplayName": "Server Type", + "Category": "Server Settings", + "Description": "", + "Keywords": "server,type,internet,lan", + "FieldName": "ServerType", + "InputType": "enum", + "IsFlagArgument": false, + "ParamFieldName": "", + "IncludeInCommandLine": false, + "DefaultValue": "InternetServer", + "EnumValues": { + "InternetServer": "Internet Server", + "LanServer": "LAN Server" + } + }, + { + "DisplayName": "Server Password", + "Category": "Server Settings", + "Description": "Password to connect to the server. Change this after installing the server", + "Keywords": "password", + "FieldName": "Password", + "InputType": "password", + "IsFlagArgument": false, + "ParamFieldName": "Password", + "IncludeInCommandLine": false, + "DefaultValue": "Password123" + }, + { + "DisplayName": "RCON Password", + "Category": "Server Settings", + "Description": "Password to connect to RCON. Change this after installing the server", + "Keywords": "RCON,password", + "FieldName": "$RemoteAdminPassword", + "InputType": "password", + "IsFlagArgument": false, + "ParamFieldName": "/RocketSettings/RCON/@Password", + "IncludeInCommandLine": false, + "DefaultValue": "Password123" + }, + { + "DisplayName": "Owner", + "Category": "Server Settings", + "Description": "[Steam64 ID](https://steamidfinder.com/) of the server's owner, which gives them administrator commands and fully sets up the server", + "Keywords": "owner", + "FieldName": "Owner", + "InputType": "text", + "IsFlagArgument": false, + "ParamFieldName": "Owner", + "IncludeInCommandLine": false, + "DefaultValue": "" + }, + { + "DisplayName": "GSLT", + "Category": "Server Settings", + "Description": "Sets the [Game Server Login Token](https://steamcommunity.com/dev/managegameservers) for the server. Required for the server to appear in the server list. Use Steam App ID 304930", + "Keywords": "GSLT,token", + "FieldName": "GSLT", + "InputType": "number", + "IsFlagArgument": false, + "ParamFieldName": "GSLT", + "IncludeInCommandLine": false, + "DefaultValue": "" + }, + { + "DisplayName": "Welcome Message", + "Category": "Server Settings", + "Description": "Player welcome message", + "Keywords": "welcome,message", + "FieldName": "Welcome", + "InputType": "text", + "IsFlagArgument": false, + "ParamFieldName": "Welcome", + "IncludeInCommandLine": false, + "DefaultValue": "Welcome to Unturned. Hosted using AMP by CubeCoders" + }, + { + "DisplayName": "Player Limit", + "Category": "Server Settings", + "Description": "Maximum number of players that may connect to the server", + "Keywords": "players,limit", + "FieldName": "$MaxUsers", + "InputType": "number", + "IsFlagArgument": false, + "ParamFieldName": "Maxplayers", + "IncludeInCommandLine": false, + "DefaultValue": "10", + "suffix": "players" + }, + { + "DisplayName": "Map", + "Category": "Server Settings", + "Description": "Sets the map", + "Keywords": "map", + "FieldName": "Map", + "InputType": "text", + "IsFlagArgument": false, + "ParamFieldName": "Map", + "IncludeInCommandLine": false, + "DefaultValue": "PEI" + }, + { + "DisplayName": "Difficulty Mode", + "Category": "Server Settings", + "Description": "Sets the difficulty mode", + "Keywords": "difficulty,mode", + "FieldName": "Mode", + "InputType": "enum", + "IsFlagArgument": false, + "ParamFieldName": "Mode", + "IncludeInCommandLine": false, + "DefaultValue": "Normal", + "EnumValues": { + "Easy": "Easy", + "Normal": "Normal", + "Hard": "Hard" + } + }, + { + "DisplayName": "Perspective View", + "Category": "Server Settings", + "Description": "Sets the perspective view", + "Keywords": "perspective,view", + "FieldName": "Perspective", + "InputType": "enum", + "IsFlagArgument": false, + "ParamFieldName": "Perspective", + "IncludeInCommandLine": false, + "DefaultValue": "Both", + "EnumValues": { + "First": "First person only", + "Third": "Third person only", + "Both": "First and third person allowed", + "Vehicle": "Third person in vehicle only" + } + }, + { + "DisplayName": "Weather", + "Category": "Server Settings", + "Description": "Sets the weather", + "Keywords": "weather", + "FieldName": "Weather", + "InputType": "enum", + "IsFlagArgument": false, + "ParamFieldName": "Weather", + "IncludeInCommandLine": false, + "DefaultValue": "None", + "EnumValues": { + "None": "None", + "Storm": "Storm", + "Blizzard": "Blizzard" + } + }, + { + "DisplayName": "Day/Night Cycle Period", + "Category": "Server Settings", + "Description": "Sets the day/night cycle period", + "Keywords": "day,night,cycle", + "FieldName": "Cycle", + "InputType": "number", + "IsFlagArgument": false, + "ParamFieldName": "Cycle", + "IncludeInCommandLine": false, + "DefaultValue": "3600", + "suffix": "seconds" + }, + { + "DisplayName": "Chat Rate", + "Category": "Server Settings", + "Description": "Sets the minimum time between chat messages in order to prevent spam", + "Keywords": "chatrate", + "FieldName": "Chatrate", + "InputType": "number", + "IsFlagArgument": false, + "ParamFieldName": "Chatrate", + "IncludeInCommandLine": false, + "DefaultValue": "0", + "suffix": "seconds" + }, + { + "DisplayName": "Timeout", + "Category": "Server Settings", + "Description": "Sets the maximum ping for players before they time out (400 - 600 ms recommended)", + "Keywords": "timeout", + "FieldName": "Timeout", + "InputType": "number", + "IsFlagArgument": false, + "ParamFieldName": "Timeout", + "IncludeInCommandLine": false, + "DefaultValue": "500", + "suffix": "milliseconds" + }, + { + "DisplayName":"Workshop Items", + "Category":"Server Settings", + "Description":"Comma separated list of IDs of workshop items to install on the server", + "Keywords":"workshop,items", + "FieldName":"FileIDs", + "InputType":"text", + "IsFlagArgument":false, + "ParamFieldName":"FileIDs", + "IncludeInCommandLine":false, + "DefaultValue":"", + "placeholder":"2478247379,2566953935" + }, + { + "DisplayName":"Excluded Workshop Items", + "Category":"Server Settings", + "Description":"Comma separated list of IDs of children items to ignore when installing workshop items", + "Keywords":"workshop,children,items", + "FieldName":"ChildrenFileIDs", + "InputType":"text", + "IsFlagArgument":false, + "ParamFieldName":"ChildrenFileIDs", + "IncludeInCommandLine":false, + "DefaultValue":"", + "placeholder":"5685656858,7697679654" + }, + { + "DisplayName": "Maximum Workshop Retries", + "Category": "Server Settings", + "Description": "Sets the maximum number of retries to download workshop items", + "Keywords": "retries", + "FieldName": "MaxRetries", + "InputType": "number", + "IsFlagArgument": false, + "ParamFieldName": "MaxRetries", + "IncludeInCommandLine": false, + "DefaultValue": "2" + } +] \ No newline at end of file diff --git a/unturnedconfigfile.dat b/unturnedconfigfile.dat new file mode 100644 index 0000000..72a7810 --- /dev/null +++ b/unturnedconfigfile.dat @@ -0,0 +1,13 @@ +Port 27015 +Password Password123 +Owner +GSLT +Welcome Welcome to Unturned. Hosted using AMP by CubeCoders +Maxplayers 10 +Map PEI +Mode Normal +Perspective Both +Weather None +Cycle 3600 +Chatrate 0 +Timeout 500 \ No newline at end of file diff --git a/unturnedmetaconfig.json b/unturnedmetaconfig.json new file mode 100644 index 0000000..c7e7f04 --- /dev/null +++ b/unturnedmetaconfig.json @@ -0,0 +1,20 @@ +[ + { + "ConfigFile": "Servers/{{ServerName}}/Server/Commands.dat", + "AutoMap": true, + "ConfigType": "kvp", + "ConfigFormat": "{0} {1}", + "ConfigFormatRegex": "^(?.+?) (?.*?)$" + }, + { + "ConfigFile": "Servers/{{ServerName}}/WorkshopDownloadConfig.json", + "AutoMap": true, + "ConfigType": "template", + "ConfigFileTemplate": "unturnedworkshopconfig.json" + }, + { + "ConfigFile": "Servers/{{ServerName}}/Rocket/Rocket.config.xml", + "AutoMap": true, + "ConfigType": "xml" + } +] diff --git a/unturnedworkshopconfig.json b/unturnedworkshopconfig.json new file mode 100644 index 0000000..6ba7a13 --- /dev/null +++ b/unturnedworkshopconfig.json @@ -0,0 +1,11 @@ +{ + "File_IDs": [{{FileIDs}}], + "Ignore_Children_File_IDs": [{{ChildrenFileIDs}}], + "Query_Cache_Max_Age_Seconds": 600, + "Max_Query_Retries": {{MaxRetries}}, + "Use_Cached_Downloads": true, + "Should_Monitor_Updates": true, + "Shutdown_Update_Detected_Timer": 600, + "Shutdown_Update_Detected_Message": "Workshop file update detected, shutdown in: {0}", + "Shutdown_Kick_Message": "Shutdown for Workshop file update." +} \ No newline at end of file