User:Rain/Sandbox: Difference between revisions

From Pavlov VR Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
(25 intermediate revisions by the same user not shown)
Line 1: Line 1:
RCON (Remote Console) is the method Pavlov VR servers can be controlled from outside of VR.
'''TODO: Rename the page to "Dedicated server" because THIS IS NOT A GUIDE!'''


== RCON Tools ==
== Hosting ==
- <nowiki>http://pavlovrcon.com/</nowiki>


- TBD: add more
'''There are no Windows binaries'''
=== Server requirements ===
'''OS''': Linux (Ubuntu 18.04 x86_64, Ubuntu 19/04 amd64, Ubuntu 20.04, and Rocky Linux 8 are confirmed working)


== RCON Commands ==
'''Memory''': 2GB RAM + 1GB RAM per each additional server with 10 players. More RAM is recommended for larger maps, higher player counts, or complex game modes.


'''CPU''': A ~2.5Ghz CPU will comfortably support a 10 player server. A ~4Ghz CPU will comfortably support 24 players.


'''Hypothesis: PSVR and Shack players can not crossplay-connect to dedicated servers. Requires confirmation.'''
'''Note''': These are '''not''' hard limits for requirements, just suggestions for the best performance, based on experiences with many server providers on different grades of hardware.


Placeholder:
Pavlov servers are functionally single threaded.


{UniqueID} - Player ID (eg. SteamID (PCVR), ??? (Shack), ??? (PSVR))
=== Software dependencies ===


{GameMode} - See [Gamemodes]
* gdb (TODO: do you actually need gdb to run a server? wtf?)
* curl (TODO: do you actually need curl to run a server? does pavlov download stuff using curl?)
* lib32gcc1(-s1)
* libc++-dev


{TeamId} - 0 for blue, 1 for red, if there are teams
=== SteamCMD ===
The app ID for Pavlov VR dedicated servers is <code>622970</code>.


{VehicleId} - See [Vehicles]
Instructions on how to use SteamCMD are available in the [https://developer.valvesoftware.com/wiki/SteamCMD Valve Developer Community Wiki].


{MapName/ID} - See [Default maps] or find the Map ID on Mod.io (put example)
To host '''Shack Live''' (Quest) use <code>-beta shack</code>, to host '''Shack RC''' (Quest) use <code>-beta shack_beta</code>.


{SkinID} - See [Skins]
Update 29 of the PCVR version of Pavlov VR dedicated servers require you to completely break your system:
<code>sudo rm /usr/lib/x86_64-linux-gnu/libc++.so</code>
<code>sudo ln -s /usr/lib/x86_64-linux-gnu/libc++.so.1 /usr/lib/x86_64-linux-gnu/libc++.so</code>


{True/False} - Either "True" to enable or "False" to disable
'''TODO: By all that is good and fair, modifying system files like this for one piece of software is unacceptable. This can be done in a different, less intrusive way.'''


{ItemId} - See [Items]
== Configuration ==


Format:
=== Moderators, Blacklist, Whitelist ===
The following three files allow you to specify moderators, banned players, and whitelist players.


All command replies are formatted as JSON and inherit this base format:
They are required to be able to use <code>AddMod</code>, <code>Ban</code>, <code>Banlist</code>, <code>ModeratorList</code>, <code>RemoveMod</code> and <code>Unban</code> [[Rcon Overview and Commands|RCON commands]] but are otherwise optional.


{
<pre>
Pavlov/Saved/Config/mods.txt
Pavlov/Saved/Config/blacklist.txt
Pavlov/Saved/Config/whitelist.txt
</pre>'''TODO: Describe the file contents, give examples.'''


"Command": "{The command you entered}",
=== Game.ini ===
 
This file contains the majority of server configuration keys.
"Successful": "{True/False}"
It is automatically created when first starting a server, it can also be created manually. <pre>
 
Pavlov/Saved/Config/LinuxServer/Game.ini
}
</pre>


Additional command output is added to the above format. The Example Reply column below only contains this additional command output.
==== Keys ====
{| class="wikitable"
{| class="wikitable"
|+
|+Game.ini keys
!Command
!Key
!Parameters
!Allowed values
!Default value
!Description
!Description
!Example Reply
|-
|-
|Help
|bEnabled
|none
|<code>True</code><code>False</code>
|Returns the full list of commands and their parameters
|<code>True</code>
|
|Enables or disables registering with the master server to show or hide the server from the server list
"Help": [
'''TODO: confirm that this is true''', and why is this even a thing, you can't direct connect to servers anyways...
"AddMapRotation MapID GameMode",
...truncated...
],
|-
|-
|AddMapRotation
|ServerName
|
|Any ASCII text value up to 35 characters
|
|<code>DedicatedServer</code>
|
|Sets the name with which the server will be listed as
'''TODO: confirm exact maximum character limit and which characters are allowed (utf8? unicode?)'''
|-
|-
|AddMod
|MaxPlayers
|
|Integer
|
Maximum 10 for Shack, 24 for PC.
|
|<code>10</code>
|Sets the amount of available player slots
|-
|-
|Ban
|ApiKey
|
|Obsolete, leave empty.
|
|
|
|
|-
|-
|Banlist
|bSecured
|
|<code>True</code><code>False</code>
|
|<code>True</code>
|
|Enables or disables Valve Anti-Cheat (VAC)
|-
|-
|Disconnect
|bCustomServer
|
|<code>True</code><code>False</code>
|
|<code>True</code>
|
|Enables or disables "some new modding tools". Save and HTTP functions.
Required to write to <code>blacklist.txt</code> for bans.
'''TODO: specify exactly what those new modding tools are.'''
|-
|-
|EnableCompMode
|bCompetitive
|
|<code>True</code><code>False</code>
|
|<code>False</code>
|
|Enables or disables competitive mode for SND
|-
|-
|EnableVerboseLogging
|bVerboseLogging
|
|<code>True</code><code>False</code>
|
|<code>False</code>
|
|Enables or disables verbose logging.
Verbose logging mostly consists of [[Setting up a dedicated server#Verbose Logging|detailed statistics]].
This will significantly increase logging.
|-
|-
|EnableWhitelist
|bWhitelist
|
|<code>True</code><code>False</code>
|
|<code>False</code>
|
|Enables or disables usage of the whitelist, allowing only users in <code>whitelist.txt</code> to join
|-
|-
|Gag
|RefreshListTime
|
|Integer, seconds
|
|<code>10</code>
|
|Sets the interval at which the server reads changes from <code>mods.txt</code>, <code>blacklist.txt</code> and <code>whitelist.txt</code>
|-
|-
|GiveAll
|LimitedAmmoType
|
|Integer, Type ID
|
|<code>1</code>
|
|Sets the limited ammo type, see [[Setting up a dedicated server#Limited Ammo Types|Limited Ammo Types]]
|-
|-
|GiveCash
|TimeLimit
|
|Integer, minutes
|
|<code>60</code>
|
|Sets the time limit for each map
|-
|-
|GiveItem
|TickRate
|
|Integer, ticks per second
|
Recommended between 50 and 120
|
|<code>90</code>
|Sets the rate at which the server processes and updates game state information and network events.
Changes weapon de-spawn time and breaks some game modes. Recommended to leave at default value.
'''TODO: what game modes? breaks how? needs clarification.'''
|-
|-
|GiveTeamCash
|Password
|
|Integer, 1 to 4 digit pin
|
|<code>0000</code>
|
|Sets the server PIN that is required to be entered before being able to join the server.
Setting the pin to <code>0</code> or <code>0000</code> does not remove the pin but sets it to <code>0</code>.
Commenting out or leaving the value empty will remove the pin.
|-
|-
|InspectAll
|BalanceTableURL
|
|Text formatted as <code>user/repository/branch</code>
|
|<code>vankruptgames/BalancingTable/main</code>
|
|Sets the balance table Git URL to be used by the server.
See [https://github.com/vankruptgames/BalancingTable Balancing Table] for instructions.
|-
|-
|InspectPlayer
|AFKTimeLimit
|
|Integer, seconds
|
|<code>60</code>
|
|Sets the maximum amount of time a player can be idle before being automatically kicked.
Setting this to <code>0</code> will disable AFK kicking.
'''TODO: Pretty sure this is incorrect, while testing I've set it to 0 and got kicked nonetheless. Only being moderator prevents afk kicking. Requires further testing.'''
|-
|-
|InspectTeam
|bInitialized
|
|<code>True</code><code>False</code>
|
|<code>False</code>
|
|'''TODO: What does this do?'''
|-
|-
|ItemList
|DepotURL
|
|
|
|
|
|'''TODO: What does this do?'''
|-
|-
|Kick
|bBroadcast
|
|<code>True</code><code>False</code>
|
|<code>True</code>
|
|Probably enables or disables broadcasting to pavtv?
'''TODO: What does this do?'''
|}
'''TODO: Verify all default values, right now I'm just guessing'''
 
'''TODO: Sort alphabetically'''
 
For maps running a Custom gamemode (CodZ, BR, Duel, etc.) it doesn't matter which gamemode you choose, as the map will automatically override it with the custom mode.
 
==== Limited Ammo Types ====
{| class="wikitable"
|+
!AmmoType
!Name
!Description
|-
|-
|Kill
|0
|
|Unlimited
|
|Players have unlimited ammo, carry no ammo boxes and do not display an ammo count on the wrist.
|
|-
|-
|MapList
|1
|
|Limited Generic
|
|Players carry ammo boxes with a limited amount of ammo.
|
One box for each weapon class (Pistol, Submachine gun, Rifles/MGs, Shotgun, Sniper).
 
Mags and ammo boxes can be put on the chest of the player to consolidate the ammo.
 
An ammo count is displayed on the wrist.
|-
|-
|ModeratorList
|2
|
|Limited Specific
|
|Players carry ammo boxes with a limited amount of ammo.
|
One box for each weapon.
 
Mags and ammo boxes can be put on the chest of the player to consolidate the ammo.
 
An ammo count is displayed on the wrist.
|-
|-
|RefreshList
|3
|
|Custom
|
|Allows for full control over ammo by the map.
|
|-
|-
|RemoveMapRotation
|4
|
| Limited Special
|
|'''All weapons except "special" weapons are unlimited, more clarification is needed.'''
|
|-
|-
|RemoveMod
|5
|
|Boxless
|
|'''Like limited generic but without boxes? Clarification is needed.'''
|
|}
 
==== Map rotation ====
The map rotation is defined in the <code>Game.ini</code>.
 
Upon server start, the first map in the rotation will be started.
 
When a map has ended, the next map in the rotation will be started.
 
When the end of the rotation has been reached, it will start from the beginning again.
 
Mod.io maps will be downloaded and updated automatically, if required, when they are rotated to.
 
Each entry requires a separate line of the following format:<pre>
MapRotation=(MapId="Name or ID", GameMode="Game Mode")
</pre><code>Name or ID</code>: See [[Default Maps|Default maps]] or find the Map ID on Mod.io and append it to "UGC" (Example: https://mod.io/g/pavlov/m/mcdonalds has Resource ID <code>2804322</code>, the MapID to use would be <code>UGC2804322</code>)
 
<code>Game Mode</code>: See [[Gamemodes|Game Modes]].
{| class="wikitable"
|+Game modes
!GameMode
!Name
|-
|-
|ResetSND
|DM
|
|Death match
|
|
|-
|-
|PauseMatch
|KOTH
|
|King of the hill
|
|
|-
|-
|RotateMap
|GUN
|
| Gun game
|
|
|-
|-
|ServerInfo
|OITC
|
| One in the chamber
|
|
|-
|-
|SetBalanceTableURL
|SND
|
|Search and destroy
|
|
|-
|-
|SetCash
|TANKTDM
|
|WW2 Team Death Match
|
|
|-
|-
|SetLimitedAmmoType
| TDM
|
|Team Death Match
|
|
|-
|-
|SetMaxPlayers
|TTT
|
|Trouble in Terrorist Town
|
|
|-
|-
|SetPin
|WW2GUN
|
|WW2 gun game
|
|
|-
|SetPlayerSkin
|
|
|
|-
|SetTimeLimit
|
|
|
|-
|ShowNametags
|
|
|
|-
|ShutdownServer
|
|
|
|-
|-
|Slap
|ZWV
|
| Zombie wave survival
|
|
|-
|-
|SwitchMap
|HIDE
|
|The Hidden
|
|
|-
|-
|SwitchTeam
|INFECTION
|
|Hidden infection
|
|
|-
|Teleport
|
|
|
|-
|TTTAlwaysEnableSkinMenu
|
|
|
|-
|TTTEndRound
|
|
|
|-
|TTTFlushKarma
|
|
|
|-
|TTTGiveCredits
|
|
|
|-
|TTTPauseTimer
|
|
|
|-
|TTTSetKarma
|
|
|
|-
|TTTSetRole
|
|
|
|-
|-
|Unban
|PUSH
|
|Push
|
|
|-
|-
|UpdateServerName
|PH
|
|Prop hunt
|
|
|}
|}
'''TODO: move this to game modes page.'''


==== Example ====
<pre>
[/Script/Pavlov.DedicatedServer]
# This is a comment
bEnabled=True
ServerName=Your server
MaxPlayers=10
bSecured=True
bCustomServer=True
bWhitelist=False
RefreshListTime=120
LimitedAmmoType=0
TickRate=90
TimeLimit=60
Password=1234
bInitialized=False
DepotURL=
ApiKey=
bCompetitive=False
bBroadcast=True
BalanceTableURL=vankruptgames/BalancingTable/Beta_5.1
bVerboseLogging=True
AFKTimeLimit=0


Commands:<pre>
MapRotation=(MapId="datacenter", GameMode="SND")
Help                                -Returns the full list of commands
MapRotation=(MapId="UGC3094680", GameMode="SND")
Ban {UniqueID}                      -Bans the player from the server (adds them to blacklist.txt)
MapRotation=(MapId="UGC2996823", GameMode="SND")
Kick {UniqueID}                    -Kicks the player from the server
MapRotation=(MapId="sand", GameMode="SND")
Kill {UniqueID}                    -Kills the player
MapRotation=(MapId="UGC2841131", GameMode="SND")
Unban {UniqueID}                    -Unbans the player from the server (tries to remove the unique id from blacklist.txt)'
MapRotation=(MapId="UGC2829349", GameMode="SND")
Banlist                            -Shows the current list of banned players
MapRotation=(MapId="container", GameMode="SND")
AddMod {UniqueID}                  -Adds a mod ID to the mods.txt file
MapRotation=(MapId="UGC2844898", GameMode="SND")
RemoveMod {UniqueID}                -Removes a mod ID to the mods.txt file
MapRotation=(MapId="UGC2804502", GameMode="SND")
ItemList                            -Shows available items for GiveItem command
</pre>
RotateMap                          -Rotates to the next map in the game.ini
SwitchMap {MapName/ID} {GameMode}  -Switches to the map/gamemode specified, ex "SwitchMap DataCenter TDM" or "SwitchMap UGC1080326389 DM"
SwitchTeam {UniqueID} {TeamId}      -Switches the specified players team
GiveItem {UniqueID} {ItemId}        -Give the specified player the Item
GiveCash {UniqueID} {CashAmt}      -Give the specified player cash
GiveTeamCash {TeamId} {CashAmt}    -Gives all members of the teamId cash
GiveVehicle {UniqueID} {VehicleID}  -Spawns Vehicle on top of player, see below for vehicle IDs
InspectPlayer {UniqueID}            -Returns information about the player specified (PlayerName, Cash, KDA, TeamId etc)
RefreshList                        -Returns a list of players on the server (unique/steamId)
Slap {UniqueID} {damage amt}        -Inflicts damage amount on player.  From zero to 100.
ServerInfo                          -Returns information about the server (ServerName, CurrentMap, PlayerCount/MaxPlayerCount etc)
Disconnect                          -Disconnects the player from Rcon
ResetSND                            -Resets the match back to round 1 keeping the same teams
SetPlayerSkin {UniqueID} {SkinId}  -Sets the skin for the specified player, see below for IDs
SetLimitedAmmoType {0-5}            -Sets the limited ammo type for the duration of the match. See below for the different ammo types available
SetPin {####}                      -Sets the password on your server, must be 4 digits e.g. "SetPin 0000". Running SetPin without a number will remove the pin from the server.
Shownametags {True/False}          -Toggles if nametags are visible or not. Useful for tactical/realistic servers, or making trailers and taking screenshots for your maps.
Shutdown                            -Shuts down the server (Shack RC only, currently untested).


TTT-only commands:
=== RCON ===
 
The RCON password and port are configured in <code>RconSettings.txt</code>. If the file does not exist or if the values in it are empty, no RCON will be provided.<pre>
tttflushkarma {UniqueID}            -Resets a player's karma
Pavlov/Saved/Config/RconSettings.txt
tttsetkarma {UniqueID} {####}      -Sets the karma of a player to a value
tttsetrole {UniqueID}              -Currently broken
tttendround                        -Ends the round
tttpausetimer                      -Pauses the timer
TTTAlwaysEnableSkinMenu            -Enables the skin menu mid-round
</pre>
</pre>


==== Keys ====
{| class="wikitable"
!Key
!Allowed values
!Default value
!Description
|-
|Password
|Text
|<code>changeme</code>
|Sets the password used to authenticate with RCON
|-
|Port
|Integer, 0-65535
|<code>9100</code>
|Sets the port at which RCON will listen
|}


 
==== Example ====
PCVR UE5 update RCON CMDS<pre>
<pre>
AddMapRotation [MapID] [GameMode] # add a map to the servers rotation from Mod.io
Password=very secure password
AddMod [UniqueID] # add user to mods.txt on server (make an admin) and allows them to use admin menu in pause menu
Port=9100
Ban [UniqueID] # ban player permanently and add there ID to blacklist.txt on server
Banlist # shows current banned players
Disconnect # close rcon connection (should always be used when done)
EnableCompMode [True/False]
EnableVerboseLogging [True/False] # more info printed to log file on server
EnableWhitelist [True/False] # only players who are on the whitelist.txt on server may join
Gag [UniqueID] [True/False] # player cant use mic
GiveAll [TeamID] [ItemID] # give all players on team a item
GiveCash [UniqueID] CashAmt # give player cash
GiveItem [UniqueID] [ItemID] # give player item
GiveTeamCash [TeamId] [CashAmt] # give team cash
InspectAll # prints detailed status for each connected player
InspectPlayer [UniqueID] # prints detailed status for a connected player
InspectTeam [TeamID] # prints detailed status for one team of connected players
ItemList # list items in game / map (custom items built into map will list too )
Kick [UniqueID] # remove player from game
Kill [UniqueID] # kills player
MapList # shows current map rotation
ModeratorList # shows current server admins
RefreshList # shows all connected players and ID
RemoveMapRotation [MapID] [GameMode] # remove map from rotation
RemoveMod [UniqueID] # remove admin
ResetSND
PauseMatch [TimeInSeconds]
RotateMap
ServerInfo
SetBalanceTableURL [GithubURL]
SetCash [UniqueID] [CashAmt]
SetLimitedAmmoType [AmmoType]
SetMaxPlayers [MaxPlayerNumber]
SetPin [PinNumber]
SetPlayerSkin [UniqueID] [SkinID]
SetTimeLimit [TimeLimitAmount]
ShowNametags [True/False]
ShutdownServer
Slap [UniqueID] [DamageAmount]
SwitchMap [MapId] [GameMode]
SwitchTeam [UniqueID] [TeamID]
Teleport [MoveUniqueID] [ToUniqueID]
TTTAlwaysEnableSkinMenu [True/False]
TTTEndRound [WinningTeamID]
TTTFlushKarma
TTTGiveCredits [UniqueID] [CreditAmount]
TTTPauseTimer [True/False]
TTTSetKarma [UniqueID] [KarmaAmt]
TTTSetRole [UniqueID] [RoleID]
Unban [UniqueID]
UpdateServerName [ServerName]
</pre>
</pre>


== Running ==


{UniqueID} is a player's Steam ID 64. It's the 17-digit number that appears next to their names in most Rcon tools. Alternatively, if you have a player's profile URL, you can find their ID at: https://steamid.xyz/
==== Startup parameters ====
{| class="wikitable"
|+
!Parameter
!Description
|-
|
-PORT=7777
|Sets the server port to listen to.
Secondary port is <code>port + 400</code>.
For example: Base port <code>7777</code>, secondary port <code>8177</code>.
|-
|
-COMPETITIVE=1
|Enables competitive mode.
This is the same as enabling competitive move in the <code>Game.ini</code>.
|-
|
|'''TODO: Ask dev for complete list of arguments or, much easier and faster, decompile the binary and find them.'''
|}


'''Limited ammo types:'''
==== Server executable ====
With the server files, a startup script <code>PavlovServer.sh</code> is shipped. It adds global execution privileges to the server executable, and adds an argument <code>Pavlov</code> to the startup parameters.


0 = Unlimited<br />
The server executable is located in <code>Pavlov/Binaries/Linux/PavlovServer-Linux-Shipping</code> and can be executed directly. It already has global execution privileges by default.
1 = Limited Generic<br />
2 = Limited Specific<br />
3 = Custom (for modders)<br />
4 = Limited Special<br />
5 = Boxless Mode


'''Item, skin, and vehicle IDs:'''
Either of these can be used to start the server, the <code>PavlovServer.sh</code> script will forward all startup parameters to the server executable.


[http://wiki.pavlov-vr.com/index.php?title=ItemIDs A full list of all items, vehicles, and skin can be found here.]
== Shack ==
Shack servers and PCVR servers have a few differences which will be described in this section.


You can also run the ItemList command through Rcon to receive the most recent and up to date list of all items.
'''TODO: Since there are also 2 shack versions, documenting all this is a huge chore, especially for someone who doesn't touch this sh..izzle.'''


'''Game Modes:''' <br />
=== Game.ini keys ===
DM        - Death Match <br />
The following keys do not exist for Shack servers.
KOTH      - King Of The Hill <br />
GUN      - Gun Game <br />
OITC      - One In The Chamber <br />
SND      - Search and Destroy <br />
TANKTDM  - WW2 Team Death Match <br />
TDM      - Team Death Match <br />
TTT      - Trouble in Terrorist Town <br />
WW2GUN    - WW2 Gun Game <br />
ZWV      - Zombie Wave Survival <br />
HIDE      - The Hidden <br />
INFECTION - Hidden Infection <br />
PUSH      - Push <br />
PH        - Prophunt <br />
----


=== Connecting to RCON ===
* '''TODO'''


Make sure whatever port you used is open in your firewall for TCP connections. Connections are simple TCP port/telnet style connections.  
=== Custom maps ===
Shack (both versions??) do not support Mod.io and require manual upload of any custom map.


To test connecting to the rcon port and issuing simple commands use netcat or telnet: 
Also players download the custom maps directly from the server?
<pre>nc {ip address} {port}</pre>
<pre>telnet {ip address} {port}</pre>


For the password use the md5 hash of the password in the file (this may change in the future). You can get this using <pre>echo -n password | md5sum</pre>
'''TODO: Needs figuring out!'''


If successful you should get an Authenticated=1 reply
To use custom maps, the maps folder first needs to be created manually.
Pavlov/Saved/maps
Custom map folders will need to be placed into this folder.


For example:<pre>Pavlov/Saved/maps
|- SVR_Arena
|- metadata.json
|- other mod files
|- SRV_Industrial
|- metadata.json
|- ...</pre>


=== Tools available to access Rcon interface ===
==== Downloading Shack maps ====
There are multiple places where you can download shack maps. Some maps are provided by the map creator.


A good first place to start is the RCON web interface run by ArcticVR. You do this at http://pavlovrcon.com/.
* https://www.pavlovquest.com/maps
* https://pavlovhorde.com/mapsList
* #shack-map-showcase in the Pavlov VR Discord ('''TODO: link it!''')


If you want private control of your server, you will need to do a bit more work for it. At the simplest, using netcat (nc) or telnet as described above will give you basic access to all commands
=== Server executable ===
PavlovServer.sh exists for shack? does it do the same useless additional stuff?


If you want to batch commands (i.e. for moving players on to teams and triggering ResetSnd) the following script can be useful to call a pre-written batch files of commands. Call with your batch file as the first argument to the script. The file should have one command per line with first line being the hashed password as above.
Is the name of the executable the same? For both shack versions?
<pre>
#!/bin/bash
function slowcat(){ while read; do sleep .05; echo "$REPLY"; done; }
cat  $1 | slowcat | nc {ip address} {port}
</pre>


Example batchfile:
'''TODO: Needs figuring out!'''
<pre>
8b96753b29612d8c98d6b696140b5d9f
ResetSnd
Disconnect
</pre>


----
----
----
----
----
----
----
----
----
----
----
----


<br>
==== Shack Maps (Quest) ====
<hr>


'''There is a very brief example above '''
If you try to use the steps above to add maps for Shack, youll run into issues very quickly. This is because Shack has no affiliation to Steam, and therefore cannot use Steam Workshop maps like above. In the future, these steps will apply to PC servers as well, allowing a server to hold the map itself, instead of offloading to Steam.
but it was not very detailed so i wanted to add a more detailed explanation


be aware that connecting and disconnecting a lot can hurt server performance
To get started, first create the directory to hold the maps


first you need to make a shell script
<pre>mkdir -p /home/steam/pavlovserver/Pavlov/Saved/maps</pre>
<pre>nano /home/steam/test.sh</pre>
 
<pre>#!/bin/bash
function slowcat(){ while read; do sleep .15; echo "$REPLY"; done; }
cat $1 | slowcat | nc {SERVER IP} {SERVER RCON PORT}</pre>
 
now exit and save the test.sh
 
here will will make a batch file that will just hold the rcon password and cmds we want to issue
 
<pre>nano /home/steam/batch</pre>
<pre>{RCON PASSWORD CONVERTED TO MD5 HASH}
{RCON CMD}
{RCON CMD}
Disconnect</pre>
 
here the first line has to be the rcon password converted to MD5 HASH
https://www.md5hashgenerator.com/
then each line after that u can use any rcon commands
the last line must be disconnect
 
now we need to give the sh permissions to run
<pre>sudo chmod +x /home/steam/test.sh</pre>
 
to run the bash script
<pre>./home/steam/test.sh /home/steam/batch</pre>
 
so to run the script we need to ./ the .sh then after a space we need to pass the batch
 
=== Rcon access from within VR ===
 
PavlovRconWebserver, pavlov-vr-rcon and pavlov_rcon_tcl have been designed to be accessible within VR using virtual desktop view.
 
 
'''pavlov_rcon_tcl''': This is a tool designed to run on your desktop for access within VR
 
https://github.com/Oakraven79/pavlov_rcon_tcl
 
 
'''PavlovRconWebserver''' is an interface designed to be usable from everywhere all the time. (also in VR over desktop view)
<pre>Features:
Manage multiple Linux servers with multiple pavlov servers.
Start / Stop / Update
Public player lists
Do almost all rcon commands
Change the map rotation
Determine which users can do what via roles
Manage whitelists and blacklists
Integrate the player lists on all other websites
</pre>
<pre>Requirements:
Good Linux knowledge
SSH access to a linux server
</pre>


https://github.com/devinSpitz/PavlovRconWebserver
You can use any number of methods to move the map files onto the server, but ill go over the two simplest, starting with a GUI approach


While functional, the PavlovRconWebserver is still in development.
Download and install CyberDuck onto your "home" PC (Whatever PC you use for access to the server, but not the server itsself): https://cyberduck.io/


If you do plan on using this tool, we recommend asking for help on the official Discord or http://discord.spitzen.solutions, or contacting the creator on the Github page (devinspitz) for the latest info on how to use it. Failing to do so will likely result in you breaking your servers.
Next, download and unzip your map of choice from https://www.pavlovquest.com/ , https://pavlovhorde.com/mapsList, or look in #shack-map-showcase channel in the discord server.  I'm going to use Cheeto's WW2 Items test (http://www.mediafire.com/file/emyt9bs1z9u9ykw/SVR_Cheeto_Items.zip/file ) for this example, you do what you like


In the top left corner, open a connection, set the connection type to SFTP, and fill in the rest of the information. User will be root, password is whatever you set the root pw as (toor in Ubuntu by default)


'''pavlov-vr-rcon''': This is tool designed to run on your desktop for access from within VR with SND team setup
In the directory dropdown (itll say /root) go back to /


https://github.com/Krzychu81/pavlov-vr-rcon
Follow the directories until we arrive back at our "maps" folder <pre>/home/steam/pavlovserver/Pavlov/Saved/maps</pre>


=== RCON access from Discord ===
Drag and drop the unzipped map folder into the main window, in this case itll be SVR_Cheeto_Items


For the ultimate in both control and complexity of setup, use the open-source '''pavlov-bot'''. This is a discord bot that will listen for commands in your discord and execute them. Supports all RCON commands with handy features such as discord role based authentication and authorisation, player, map and team aliases (No more SteamIDs or UGC####) and enhanced "all" and team based commands. Has support for flushing non-registered players from server. Advanced features to include alerting when servers are kicking off, team killing player kick/ban and large server (PUSH/RUSH/TankTDM) player balance (count) control.
Hit Allow


For '''shack''' users it has been updated to support Oculus ids and map aliases, so is fully functional for both server versions. See Readme.md for shack specific tweaks.  
Youll now see a folder named SVR_Cheeto_Items, and within it should be nothing but 3 files. If there is another folder in it, move this folder to the maps directory, otherwise the server wont work. The 3 files (2 .PAK one .JSON) should be in home/steam/pavlovserver/Pavlov/Saved/maps/SVR_Cheeto_Items, no more, no less.


https://github.com/makupi/pavlov-bot
Pavlov Shack servers load maps at pavlovserver start. '''YOU MUST RESTART THE GAME SERVER TO USE THE MAPS.'''


'''Horde''' also offers a Discord Bot to grant RCON permissions to friends in Discord, and run commands from specific channels. Invite the Horde Bot to your Discord server with this link:
To play the map, you can either use RCON switch map command, or to add the map to your servers automatic map rotation list, add the map's folder name to your Game.ini. This replaces the MapID section, so for our example it would be
https://discord.com/oauth2/authorize?client_id=780880728992383077&scope=bot&permissions=199744


=== Tips on developing apps to use RCON ===
<pre>MapRotation=(MapId="SVR_Cheeto_Items", GameMode="TDM")</pre>
What is important if you are issuing commands using a program at high frequency is that you open one connection and put all of the commands through that open connection with a small (.1 sec is fine) delay. What you don't want to do is open a new connection for each command or shove all of the commands through super fast. First causes performance issues and the second dropped commands.


And thats all! Disconnect CyberDuck from your server before playing, otherwise youll have difficulty joining.


'''Ban/Unban'''


If you want Ban/Unban to work file /home/steam/pavlovserver/Pavlov/Saved/Config/blacklist.txt needs to be writable by user running server.  (If you followed the instructions on the wiki, username steam is running the server and creates the file).
[[Category:RCON automation]]

Latest revision as of 04:46, 6 July 2023

TODO: Rename the page to "Dedicated server" because THIS IS NOT A GUIDE!

Hosting

There are no Windows binaries

Server requirements

OS: Linux (Ubuntu 18.04 x86_64, Ubuntu 19/04 amd64, Ubuntu 20.04, and Rocky Linux 8 are confirmed working)

Memory: 2GB RAM + 1GB RAM per each additional server with 10 players. More RAM is recommended for larger maps, higher player counts, or complex game modes.

CPU: A ~2.5Ghz CPU will comfortably support a 10 player server. A ~4Ghz CPU will comfortably support 24 players.

Note: These are not hard limits for requirements, just suggestions for the best performance, based on experiences with many server providers on different grades of hardware.

Pavlov servers are functionally single threaded.

Software dependencies

  • gdb (TODO: do you actually need gdb to run a server? wtf?)
  • curl (TODO: do you actually need curl to run a server? does pavlov download stuff using curl?)
  • lib32gcc1(-s1)
  • libc++-dev

SteamCMD

The app ID for Pavlov VR dedicated servers is 622970.

Instructions on how to use SteamCMD are available in the Valve Developer Community Wiki.

To host Shack Live (Quest) use -beta shack, to host Shack RC (Quest) use -beta shack_beta.

Update 29 of the PCVR version of Pavlov VR dedicated servers require you to completely break your system:

sudo rm /usr/lib/x86_64-linux-gnu/libc++.so 
sudo ln -s /usr/lib/x86_64-linux-gnu/libc++.so.1 /usr/lib/x86_64-linux-gnu/libc++.so

TODO: By all that is good and fair, modifying system files like this for one piece of software is unacceptable. This can be done in a different, less intrusive way.

Configuration

Moderators, Blacklist, Whitelist

The following three files allow you to specify moderators, banned players, and whitelist players.

They are required to be able to use AddMod, Ban, Banlist, ModeratorList, RemoveMod and Unban RCON commands but are otherwise optional.

Pavlov/Saved/Config/mods.txt
Pavlov/Saved/Config/blacklist.txt
Pavlov/Saved/Config/whitelist.txt

TODO: Describe the file contents, give examples.

Game.ini

This file contains the majority of server configuration keys.

It is automatically created when first starting a server, it can also be created manually.

Pavlov/Saved/Config/LinuxServer/Game.ini

Keys

Game.ini keys
Key Allowed values Default value Description
bEnabled TrueFalse True Enables or disables registering with the master server to show or hide the server from the server list

TODO: confirm that this is true, and why is this even a thing, you can't direct connect to servers anyways...

ServerName Any ASCII text value up to 35 characters DedicatedServer Sets the name with which the server will be listed as

TODO: confirm exact maximum character limit and which characters are allowed (utf8? unicode?)

MaxPlayers Integer

Maximum 10 for Shack, 24 for PC.

10 Sets the amount of available player slots
ApiKey Obsolete, leave empty.
bSecured TrueFalse True Enables or disables Valve Anti-Cheat (VAC)
bCustomServer TrueFalse True Enables or disables "some new modding tools". Save and HTTP functions.

Required to write to blacklist.txt for bans. TODO: specify exactly what those new modding tools are.

bCompetitive TrueFalse False Enables or disables competitive mode for SND
bVerboseLogging TrueFalse False Enables or disables verbose logging.

Verbose logging mostly consists of detailed statistics. This will significantly increase logging.

bWhitelist TrueFalse False Enables or disables usage of the whitelist, allowing only users in whitelist.txt to join
RefreshListTime Integer, seconds 10 Sets the interval at which the server reads changes from mods.txt, blacklist.txt and whitelist.txt
LimitedAmmoType Integer, Type ID 1 Sets the limited ammo type, see Limited Ammo Types
TimeLimit Integer, minutes 60 Sets the time limit for each map
TickRate Integer, ticks per second

Recommended between 50 and 120

90 Sets the rate at which the server processes and updates game state information and network events.

Changes weapon de-spawn time and breaks some game modes. Recommended to leave at default value. TODO: what game modes? breaks how? needs clarification.

Password Integer, 1 to 4 digit pin 0000 Sets the server PIN that is required to be entered before being able to join the server.

Setting the pin to 0 or 0000 does not remove the pin but sets it to 0. Commenting out or leaving the value empty will remove the pin.

BalanceTableURL Text formatted as user/repository/branch vankruptgames/BalancingTable/main Sets the balance table Git URL to be used by the server.

See Balancing Table for instructions.

AFKTimeLimit Integer, seconds 60 Sets the maximum amount of time a player can be idle before being automatically kicked.

Setting this to 0 will disable AFK kicking. TODO: Pretty sure this is incorrect, while testing I've set it to 0 and got kicked nonetheless. Only being moderator prevents afk kicking. Requires further testing.

bInitialized TrueFalse False TODO: What does this do?
DepotURL TODO: What does this do?
bBroadcast TrueFalse True Probably enables or disables broadcasting to pavtv?

TODO: What does this do?

TODO: Verify all default values, right now I'm just guessing

TODO: Sort alphabetically

For maps running a Custom gamemode (CodZ, BR, Duel, etc.) it doesn't matter which gamemode you choose, as the map will automatically override it with the custom mode.

Limited Ammo Types

AmmoType Name Description
0 Unlimited Players have unlimited ammo, carry no ammo boxes and do not display an ammo count on the wrist.
1 Limited Generic Players carry ammo boxes with a limited amount of ammo.

One box for each weapon class (Pistol, Submachine gun, Rifles/MGs, Shotgun, Sniper).

Mags and ammo boxes can be put on the chest of the player to consolidate the ammo.

An ammo count is displayed on the wrist.

2 Limited Specific Players carry ammo boxes with a limited amount of ammo.

One box for each weapon.

Mags and ammo boxes can be put on the chest of the player to consolidate the ammo.

An ammo count is displayed on the wrist.

3 Custom Allows for full control over ammo by the map.
4 Limited Special All weapons except "special" weapons are unlimited, more clarification is needed.
5 Boxless Like limited generic but without boxes? Clarification is needed.

Map rotation

The map rotation is defined in the Game.ini.

Upon server start, the first map in the rotation will be started.

When a map has ended, the next map in the rotation will be started.

When the end of the rotation has been reached, it will start from the beginning again.

Mod.io maps will be downloaded and updated automatically, if required, when they are rotated to.

Each entry requires a separate line of the following format:

MapRotation=(MapId="Name or ID", GameMode="Game Mode")

Name or ID: See Default maps or find the Map ID on Mod.io and append it to "UGC" (Example: https://mod.io/g/pavlov/m/mcdonalds has Resource ID 2804322, the MapID to use would be UGC2804322)

Game Mode: See Game Modes.

Game modes
GameMode Name
DM Death match
KOTH King of the hill
GUN Gun game
OITC One in the chamber
SND Search and destroy
TANKTDM WW2 Team Death Match
TDM Team Death Match
TTT Trouble in Terrorist Town
WW2GUN WW2 gun game
ZWV Zombie wave survival
HIDE The Hidden
INFECTION Hidden infection
PUSH Push
PH Prop hunt

TODO: move this to game modes page.

Example

[/Script/Pavlov.DedicatedServer]
# This is a comment
bEnabled=True
ServerName=Your server
MaxPlayers=10
bSecured=True
bCustomServer=True
bWhitelist=False
RefreshListTime=120
LimitedAmmoType=0
TickRate=90
TimeLimit=60
Password=1234
bInitialized=False
DepotURL=
ApiKey=
bCompetitive=False
bBroadcast=True
BalanceTableURL=vankruptgames/BalancingTable/Beta_5.1
bVerboseLogging=True
AFKTimeLimit=0

MapRotation=(MapId="datacenter", GameMode="SND")
MapRotation=(MapId="UGC3094680", GameMode="SND")
MapRotation=(MapId="UGC2996823", GameMode="SND")
MapRotation=(MapId="sand", GameMode="SND")
MapRotation=(MapId="UGC2841131", GameMode="SND")
MapRotation=(MapId="UGC2829349", GameMode="SND")
MapRotation=(MapId="container", GameMode="SND")
MapRotation=(MapId="UGC2844898", GameMode="SND")
MapRotation=(MapId="UGC2804502", GameMode="SND")

RCON

The RCON password and port are configured in RconSettings.txt. If the file does not exist or if the values in it are empty, no RCON will be provided.

Pavlov/Saved/Config/RconSettings.txt

Keys

Key Allowed values Default value Description
Password Text changeme Sets the password used to authenticate with RCON
Port Integer, 0-65535 9100 Sets the port at which RCON will listen

Example

Password=very secure password
Port=9100

Running

Startup parameters

Parameter Description
-PORT=7777
Sets the server port to listen to.

Secondary port is port + 400. For example: Base port 7777, secondary port 8177.

-COMPETITIVE=1
Enables competitive mode.

This is the same as enabling competitive move in the Game.ini.

TODO: Ask dev for complete list of arguments or, much easier and faster, decompile the binary and find them.

Server executable

With the server files, a startup script PavlovServer.sh is shipped. It adds global execution privileges to the server executable, and adds an argument Pavlov to the startup parameters.

The server executable is located in Pavlov/Binaries/Linux/PavlovServer-Linux-Shipping and can be executed directly. It already has global execution privileges by default.

Either of these can be used to start the server, the PavlovServer.sh script will forward all startup parameters to the server executable.

Shack

Shack servers and PCVR servers have a few differences which will be described in this section.

TODO: Since there are also 2 shack versions, documenting all this is a huge chore, especially for someone who doesn't touch this sh..izzle.

Game.ini keys

The following keys do not exist for Shack servers.

  • TODO

Custom maps

Shack (both versions??) do not support Mod.io and require manual upload of any custom map.

Also players download the custom maps directly from the server?

TODO: Needs figuring out!

To use custom maps, the maps folder first needs to be created manually.

Pavlov/Saved/maps

Custom map folders will need to be placed into this folder.

For example:

Pavlov/Saved/maps
|- SVR_Arena
 |- metadata.json
 |- other mod files
|- SRV_Industrial
 |- metadata.json
 |- ...

Downloading Shack maps

There are multiple places where you can download shack maps. Some maps are provided by the map creator.

Server executable

PavlovServer.sh exists for shack? does it do the same useless additional stuff?

Is the name of the executable the same? For both shack versions?

TODO: Needs figuring out!













Shack Maps (Quest)

If you try to use the steps above to add maps for Shack, youll run into issues very quickly. This is because Shack has no affiliation to Steam, and therefore cannot use Steam Workshop maps like above. In the future, these steps will apply to PC servers as well, allowing a server to hold the map itself, instead of offloading to Steam.

To get started, first create the directory to hold the maps

mkdir -p /home/steam/pavlovserver/Pavlov/Saved/maps

You can use any number of methods to move the map files onto the server, but ill go over the two simplest, starting with a GUI approach

Download and install CyberDuck onto your "home" PC (Whatever PC you use for access to the server, but not the server itsself): https://cyberduck.io/

Next, download and unzip your map of choice from https://www.pavlovquest.com/ , https://pavlovhorde.com/mapsList, or look in #shack-map-showcase channel in the discord server. I'm going to use Cheeto's WW2 Items test (http://www.mediafire.com/file/emyt9bs1z9u9ykw/SVR_Cheeto_Items.zip/file ) for this example, you do what you like

In the top left corner, open a connection, set the connection type to SFTP, and fill in the rest of the information. User will be root, password is whatever you set the root pw as (toor in Ubuntu by default)

In the directory dropdown (itll say /root) go back to /

Follow the directories until we arrive back at our "maps" folder

/home/steam/pavlovserver/Pavlov/Saved/maps

Drag and drop the unzipped map folder into the main window, in this case itll be SVR_Cheeto_Items

Hit Allow

Youll now see a folder named SVR_Cheeto_Items, and within it should be nothing but 3 files. If there is another folder in it, move this folder to the maps directory, otherwise the server wont work. The 3 files (2 .PAK one .JSON) should be in home/steam/pavlovserver/Pavlov/Saved/maps/SVR_Cheeto_Items, no more, no less.

Pavlov Shack servers load maps at pavlovserver start. YOU MUST RESTART THE GAME SERVER TO USE THE MAPS.

To play the map, you can either use RCON switch map command, or to add the map to your servers automatic map rotation list, add the map's folder name to your Game.ini. This replaces the MapID section, so for our example it would be

MapRotation=(MapId="SVR_Cheeto_Items", GameMode="TDM")

And thats all! Disconnect CyberDuck from your server before playing, otherwise youll have difficulty joining.