User:Barrowisp/Draft2: Difference between revisions

From Vintage Story Wiki
(standardized)
No edit summary
Line 10: Line 10:
==== Dedicated Servers on Windows ====  
==== Dedicated Servers on Windows ====  


To keep your multiplayer server's settings from interfering with your single-player settings, use a custom --dataPath argument.  Shortcut method:
To keep your multiplayer server's settings from interfering with your single-player settings, use a custom --dataPath argument.   


'''Shortcut method:'''
# Navigate to the location where you will store the server's data, such as a new VintagestoryServer folder created in <code>C:\Users\YourUsername\AppData\Roaming</code>
# Navigate to the location where you will store the server's data, such as a new VintagestoryServer folder created in <code>C:\Users\YourUsername\AppData\Roaming</code>
# Create a folder for the server's data and give it a clear name, such as VSserverData
# Create a folder for the server's data and give it a clear name, such as VSserverData
Line 21: Line 22:
* Optional: you can move/copy the shortcut, to your desktop and/or your new VintagestoryServer folder
* Optional: you can move/copy the shortcut, to your desktop and/or your new VintagestoryServer folder


Batch script method (functionally equivalent to the shortcut method above):
'''Batch script method''' (functionally equivalent to the shortcut method above):
# To create a batch script, simply create a blank text document and rename it with the .bat file extension.   
# To create a batch script, simply create a blank text document and rename it with the .bat file extension.   
# You can edit it by right clicking and selecting edit.  Then just type <code>%appdata%/Vintagestory/VintagestoryServer.exe --dataPath "[PATH]"</code>  replacing [PATH] with the desired path for the server's data, then save and close.   
# You can edit it by right clicking and selecting edit.  Then just type <code>%appdata%/Vintagestory/VintagestoryServer.exe --dataPath "[PATH]"</code>  replacing [PATH] with the desired path for the server's data, then save and close.   
Line 28: Line 29:
Next:  
Next:  
* Run the ''shortcut you made'' of <code>VintagestoryServer.exe</code> or the batch script.
* Run the ''shortcut you made'' of <code>VintagestoryServer.exe</code> or the batch script.
* If Windows Firewall asks for permission, grant any necessary access
* If Windows Firewall asks for permission, grant any necessary access.
* You might need to forward port 42420 on your internet router if you want the server to be accessible from outside of your local network (for example, anyone who isn't on the same WiFi as you).
* You might need to forward port 42420 on your internet router if you want the server to be accessible from outside of your local network (for example, anyone who isn't on the same WiFi as you).  The process for this depends on your router model.


{Where should they turn if the above didn't work as expected?}
{Where should they turn if the above didn't work as expected?}

Revision as of 00:54, 17 March 2024

Dedicated Server

Alternatively the game ships with a dedicated server program that you can start and leave on permanently without needing to log in yourself. There are several ways to get a dedicated server up and running.

See List of server hosting providers

Dedicated Servers on Windows

To keep your multiplayer server's settings from interfering with your single-player settings, use a custom --dataPath argument.

Shortcut method:

  1. Navigate to the location where you will store the server's data, such as a new VintagestoryServer folder created in C:\Users\YourUsername\AppData\Roaming
  2. Create a folder for the server's data and give it a clear name, such as VSserverData
  3. Open that folder and select the entire path from the address bar of File Explorer. (example: C:\Users\YourUsername\AppData\Roaming\VintagestoryServer\VSserverData)
  4. Open the game's application folder, it is %appdata%/VintageStory by default.
  5. Create a shortcut of VintagestoryServer.exe. This can usually be accomplished through the right-click menu; google instructions specific to your operating system version if needed.
  6. Open the Properties of the new shortcut. This can usually be accomplished through the right-click menu.
  7. Click in the Target field of the shortcut's Properties, then go to the very end of what's written there. Add one space, then --dataPath=, then Paste the folder path you copied earlier, in quotes. The entire contents of the Target field should now be something like this: "C:\Users\YourUsername\AppData\Roaming\Vintagestory\VintagestoryServer.exe" --dataPath="C:\Users\YourUsername\AppData\Roaming\VintagestoryServer\VSserverData"
  • Optional: you can move/copy the shortcut, to your desktop and/or your new VintagestoryServer folder

Batch script method (functionally equivalent to the shortcut method above):

  1. To create a batch script, simply create a blank text document and rename it with the .bat file extension.
  2. You can edit it by right clicking and selecting edit. Then just type %appdata%/Vintagestory/VintagestoryServer.exe --dataPath "[PATH]" replacing [PATH] with the desired path for the server's data, then save and close.

Running the script will run the server with the alternate datapath, and will generate its own collection of config files there. This is functionally equivalent to the modified link.

Next:

  • Run the shortcut you made of VintagestoryServer.exe or the batch script.
  • If Windows Firewall asks for permission, grant any necessary access.
  • You might need to forward port 42420 on your internet router if you want the server to be accessible from outside of your local network (for example, anyone who isn't on the same WiFi as you). The process for this depends on your router model.

{Where should they turn if the above didn't work as expected?} {What will they see next if it did work?}

Using Windows on a virtual machine

There are some reports that LAN connection to a Vintage Story server running inside a Windows virtual machine (VM) can be slow, even when internet (WAN) connections have normal performance. This may depend on VM solution and network drivers. If this affects you, a suggested workaround is to use the Paravirtualized network adapter (virtio-net) for network adapters. The drivers are located here.