{"id":356,"date":"2023-03-28T23:56:48","date_gmt":"2023-03-29T03:56:48","guid":{"rendered":"https:\/\/dinogenonline.com\/?p=356"},"modified":"2023-03-28T23:50:50","modified_gmt":"2023-03-29T03:50:50","slug":"multiplayer-server-guide","status":"publish","type":"post","link":"https:\/\/dinogenonline.com\/multiplayer-server-guide\/","title":{"rendered":"Multiplayer Server Guide"},"content":{"rendered":"\n<p>Anyone can quickly setup and host a Dinogen Online multiplayer server for free!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Setup<\/h2>\n\n\n\n<p>In order to host your own Dinogen Online server, you must have&nbsp;<strong>npm<\/strong>&nbsp;on the device you want to run the server on. It&#8217;s recommended to have basic command-line experience beforehand.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">What is npm?<\/h3>\n\n\n\n<p><strong>npm<\/strong> (Node Package Manager) is an online repository for the publishing of open-source Node.js projects. It&#8217;s also a command-line utility for interacting with said repository that aids in package installation, version management, and dependency management.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Node Installation<\/h3>\n\n\n\n<p>To check if you already have npm and Node installed:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>npm -v\nnode -v<\/code><\/pre>\n\n\n\n<p>If installed, these will output the currently installed version. Node v16+ is required to run a Dinogen Online multiplayer server.<\/p>\n\n\n\n<p>If not installed, follow the installation directions for your operating system: <a href=\"https:\/\/nodejs.org\/en\/download\/\" target=\"_blank\" rel=\"noopener\" title=\"\">https:\/\/nodejs.org\/en\/download\/<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Method 1: Dinogen Online Multiplayer Server Tool<\/h2>\n\n\n\n<p>Use the&nbsp;<strong>Dinogen Online Multiplayer Server<\/strong>&nbsp;tool in your Steam library to easily launch a multiplayer server. This tool is automatically included when you install <a href=\"https:\/\/store.steampowered.com\/app\/2152990\/Dinogen_Online\/\" target=\"_blank\" rel=\"noopener\" title=\"Dinogen Online\">Dinogen Online on Steam<\/a>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"543\" height=\"309\" src=\"https:\/\/dinogenonline.com\/wp-content\/uploads\/2023\/03\/dinogen_mp.png\" alt=\"\" class=\"wp-image-359\" srcset=\"https:\/\/dinogenonline.com\/wp-content\/uploads\/2023\/03\/dinogen_mp.png 543w, https:\/\/dinogenonline.com\/wp-content\/uploads\/2023\/03\/dinogen_mp-300x171.png 300w\" sizes=\"(max-width: 543px) 100vw, 543px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Method 2: Repository<\/h2>\n\n\n\n<p>Contact&nbsp;<strong>WilkinGames#7992<\/strong>&nbsp;on Discord for repository access to the Dinogen Online multiplayer server.<\/p>\n\n\n\n<p>Navigate to the directory you want to run the server from and clone the repository:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>git clone &lt;url&gt;<\/code><\/pre>\n\n\n\n<p>Install the dependencies:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>npm install<\/code><\/pre>\n\n\n\n<p>Now you can start the multiplayer server:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>npm start<\/code><\/pre>\n\n\n\n<p>You should see the following output if successful:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>Dinogen Online | Multiplayer Server | x.x.x | Game Version: x.x.x\n...\nListening on IPv6 :::9000<\/code><\/pre>\n\n\n\n<p>Congratulations! You are now running a Dinogen Online multiplayer server. You can verify by opening the following page in your browser:&nbsp;<a href=\"http:\/\/localhost:9000\" target=\"_blank\" rel=\"noopener\" title=\"\">http:\/\/localhost:9000\/<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Configuration<\/h2>\n\n\n\n<p>You can configure server settings by modifying the&nbsp;<strong>settings.json<\/strong>&nbsp;file in the root directory.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>Property<\/th><th>Description<\/th><\/tr><\/thead><tbody><tr><td>name<\/td><td>Server name<\/td><\/tr><tr><td>country<\/td><td>2-letter country code, useful if hosting the server externally<\/td><\/tr><tr><td>port<\/td><td>Port to run the server on (default 9000)<\/td><\/tr><tr><td>maxPlayers<\/td><td>Maximum players that can connect simultaneously<\/td><\/tr><tr><td>welcome<\/td><td>Welcome message to display when a player connects<\/td><\/tr><tr><td>rules<\/td><td>Server rules<\/td><\/tr><tr><td>bAllowVotekick<\/td><td>Enable votekick for public lobbies<\/td><\/tr><tr><td>bAllowVoteskip<\/td><td>Enable voteskip for public lobbies<\/td><\/tr><tr><td>bAllowVotes<\/td><td>Enable map voting for public lobbies<\/td><\/tr><tr><td>bDisableDummies<\/td><td>If true, multiplayer bots will not be added<\/td><\/tr><tr><td>bPersistentStats<\/td><td>Server stats are saved to a file, keeping them persistent when the server is restarted<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>The server must be restarted for any changes to take effect.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Server Management<\/h2>\n\n\n\n<p>Server side updates are frequently released. Each time you start the multiplayer server, make sure you&#8217;re using the latest version. You&#8217;ll need to restart the server in order for changes to take effect.<\/p>\n\n\n\n<p>The Dinogen Online Multiplayer Server tool will automatically update via Steam.<\/p>\n\n\n\n<p>If you are using the repository, to update the server code to the latest version:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>git pull\nnpm install\nnpm start<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">PM2<\/h2>\n\n\n\n<p>It&#8217;s useful to automatically restart the server in the event it stops for any reason. Using&nbsp;<strong>PM2<\/strong>&nbsp;handles this, ensuring the server remains online until you explicitly stop it. This is particularly useful if you are hosting on an external service.<\/p>\n\n\n\n<p>Learn more about PM2:&nbsp;<a href=\"https:\/\/pm2.keymetrics.io\/\" target=\"_blank\" rel=\"noopener\" title=\"\">https:\/\/pm2.keymetrics.io\/<\/a><\/p>\n\n\n\n<p>Install PM2:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>npm install pm2 -g<\/code><\/pre>\n\n\n\n<p>Start the server with PM2:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>pm2 start server.js --name dinogen-online<\/code><\/pre>\n\n\n\n<p>PM2 also provides some useful commands:<\/p>\n\n\n\n<pre class=\"wp-block-code has-kubio-color-5-color has-kubio-color-6-background-color has-text-color has-background\"><code>pm2 list\npm2 logs\npm2 monitor<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Connecting to the Server<\/h2>\n\n\n\n<p>You can connect to the server by selecting the <strong>Connect By URL<\/strong> button in the Multiplayer menu.<\/p>\n\n\n\n<p>You can also add the server URL to the Server Browser by clicking <strong>Add Server<\/strong>.<\/p>\n\n\n\n<p>Locally hosted servers are hosted at <a href=\"http:\/\/localhost:9000\" target=\"_blank\" rel=\"noopener\" title=\"http:\/\/localhost:9000\">http:\/\/localhost:9000<\/a> (default port).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Quick guide for hosting your own Dinogen Online multiplayer server.<\/p>\n","protected":false},"author":1,"featured_media":405,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"saved_in_kubio":false,"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[15],"tags":[18,16,17],"class_list":["post-356","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-guides","tag-guide","tag-multiplayer","tag-server"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/posts\/356","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/comments?post=356"}],"version-history":[{"count":16,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/posts\/356\/revisions"}],"predecessor-version":[{"id":437,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/posts\/356\/revisions\/437"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/media\/405"}],"wp:attachment":[{"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/media?parent=356"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/categories?post=356"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dinogenonline.com\/wp-json\/wp\/v2\/tags?post=356"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}