Author Topic: Dedicated Server  (Read 1432 times)

Is there a different way of setting up a dedicated server now? I searched my comp and can't find the dedicated server launcher. Please help, I really want to set up a dedicated server so I don't have to be in it constantly.

This guide is pretty helpful, so I'm reposting it for you.


Creating a Dedicated Server (for Windows)

First, make a copy of your Blockland shortcut. Then right click on the new copy of the shortcut and go to Properties. Click the Shortcut tab.

The target field will look something like this:
Code: [Select]
"C:\Program Files (x86)\Blockland\BlocklandLauncher.exe"
To make this launch a dedicated server, add the -dedicated parameter to the end. It should now look like this:
Code: [Select]
"C:\Program Files (x86)\Blockland\BlocklandLauncher.exe" -dedicatedYou can now launch the server using that shortcut, but I recommend that you read below first.

(Optional) If you wish to start a specific game mode, add the -gamemode Name_of_GameMode parameter to the end of the target. If you don't do this, the server will default to the standard/custom mode. (which allows you to set your own add-ons and customize everything)

(Optional, but recommended) Set your dedicated server to use its own directory. (if you don't do this, it will use your current BL directory) Add this parameter to the end of your shortcut's target: -profilePath "C:\path\to\server folder"



Setting Up Your Server

Before you perform these steps, you should start your server at least once and then close it - doing so will create the pref files for you to edit. Note, these steps should be performed while the server is closed.

To change server settings, open the file called "prefs.cs" in the "config/server" folder.

To change which add-ons are enabled, open the file called "ADD_ON_LIST.cs" in the "config/server" folder. A 1 next to an add-on indicates it is enabled while a -1 indicates it is disabled.

To install new add-ons, simply place them in the add-ons folder.



Shutting Down Your Server

This might seem trivial, but most people don't know how to do this properly.

To shut down your server, enter quit(); in the server console.
[/size]

Let me elaborate on this:
(Optional, but recommended) Set your dedicated server to use its own directory. (if you don't do this, it will use your current BL directory) Add this parameter to the end of your shortcut's target: -profilePath "C:\path\to\server folder"

It is recommended that you use a separate folder so that you don't have two Blockland copies running on top of each other. It does technically work, but it can be very confusing.

When I create the new directory for the server, I copy my Addons folder into it, correct?

When I create the new directory for the server, I copy my Addons folder into it, correct?
Yes.

Wait, do I just completely copy my whole BL directory and make the shortcut?

Wait, do I just completely copy my whole BL directory and make the shortcut?
You don't have to do that. You can always make the dedicated server to make the directory for you.

You don't have to do that. You can always make the dedicated server to make the directory for you.

So is there a way to make the dedicated server create the directory that uses all of the addons I have selected for the non-dedicated server?

So is there a way to make the dedicated server create the directory that uses all of the addons I have selected for the non-dedicated server?
If you want to do that, then I recommend that you run the dedicated server shortcut so it creates the new directory. After it has been created, copy all of your files from your main Blockland directory and paste it into the new one that the dedicated server will use.

So I could create the directory, put the shortcut in it, add the -dedicated, and then add -profilePath with the path to the directory I put the shortcut in after it, and then copy the mods into it?

Just making sure I understand it all.

Sorry, I meant to say files, not mods.

So I could create the directory, put the shortcut in it, add the -dedicated, and then add -profilePath with the path to the directory I put the shortcut in after it, and then copy the mods into it?

Just making sure I understand it all.
Yeah that should work.

So I tried running the shortcut and it says "Try running the game from the launcher."

So I tried running the shortcut and it says "Try running the game from the launcher."
You have to go to your launcher's directory and make the shortcut from that Blockland Launcher file. The launcher directory is usually in C:\Blockland, C:\Program Files\Blockland, or C:\Program Files (x86)\Blockland.

Ok so I got it up and running, put my key in, copied the config from my Blockland directory into the dedicated server, and launched it again. But now it won't let me connect in game. It doesn't connect to the server at all.