How to Package a Dedicated Server in Unreal Engine



How to build Unreal Engine from Source: https://youtu.be/MRJUWC90aJM

In this video, we go over how to set up and package a dedicated server for your Unreal Engine project. Dedicated servers are becoming a popular alternative to other game server options such as listen servers and peer-to-peer for multiplayer games. Dedicated servers provide many advantages over having clients partake in hosting the game such as security, reliability, fairness, and better performance. However, dedicated game server hosting involves a separate machine and program running from the client. The unreal engine game server program is somewhat different than the client program in that the server is typically headless, meaning that it doesn’t render graphics, device input, sound, and other player-oriented features because the server’s main responsibility is to use client request information to update the state of the game world and that the clients have the data required to recreate that game world while being efficient. Therefore, packaging an Unreal Engine project as a dedicated server requires a different build configuration. At the end of this tutorial, we run the server locally in order to test some simple client connections and gameplay interaction.

*****IMPORTANT LINKS*****
Unreal Engine documentation articles on dedicated servers:
https://docs.unrealengine.com/en-US/InteractiveExperiences/Networking/HowTo/DedicatedServers/index.html
https://docs.unrealengine.com/en-US/InteractiveExperiences/Networking/Overview/index.html
https://docs.unrealengine.com/en-US/InteractiveExperiences/Networking/Server/index.html
Other useful webpages on dedicated servers:
https://en.wikipedia.org/wiki/Game_server

What Is a Dedicated Server for Gaming? And Why You Need It


More information about target files for Unreal Engine: https://docs.unrealengine.com/en-US/ProductionPipelines/BuildTools/UnrealBuildTool/TargetFiles/index.html

Commands:
Run a UE4 server build locally with logs: [name-of-server-executable].exe -log
Connect to localhost from a UE4 client build: open 127.0.0.1

How to support the channel:
Get a shirt or sweatshirt with free shipping (Use code “SHIP” at checkout): https://teespring.com/stores/flopperam
Become a member: https://www.youtube.com/channel/UCO77KLKwplncMHLo6gLpIHw/join
Support us on Patreon: https://www.patreon.com/flopperam
Donate to our PayPal: https://www.paypal.me/flopperam
Sponsor us on Github: https://github.com/sponsors/chris-gong

Social media links:
Discord: https://discord.gg/8yvTRBv
Twitter: https://twitter.com/Flopperam
Instagram: https://www.instagram.com/flopperam/
Facebook: https://www.facebook.com/flopperam

Music Creds:
Song: LAKEY INSPIRED – Chill Day (Vlog No Copyright Music)
Music provided by Vlog No Copyright Music.
Video Link: https://youtu.be/vtHGESuQ22s

Song: LAKEY INSPIRED – Doing Just Fine
Video Link: https://www.youtube.com/watch?v=rft-wpNtt-w
Youtube Channel Link: https://www.youtube.com/channel/UCOmy8wuTpC95lefU5d1dt2Q

13 thoughts on “How to Package a Dedicated Server in Unreal Engine

  1. Excellent explanation. I've been looking around for something like this for a long time. I will take this same approach and apply it to a Linux Dedicated Server, which really what I am looking to complete for my project.

    My plan is to select Development Server and then choose Linux as the solution platform and build in VS2019. I will then go back into UE4 and build the server in the same way we generated the Windows Server. I believe this should work.

    I'll add on a reply to this message with the results. Again, thanks for paving the way!

  2. I can't thank you enough for this amazing content!
    This video is my 3rd trial on setting up my first dedicated server and third time's the charm I guess.
    Great content such as this makes it possible for me to work full time in a factory and learn game development simultaneously. You make it possible for me to leave that part of my life in the past and move onto bigger and better things.

  3. Hi, I found this dedicated Server cannot make ios connect with any other devices(Android meeting with PC on this server was fine). iOS app will crash when other platform join server. Is there any idea to fix it ? And I also wonder why there is so much games support multi-play with multi-platform ? How they build it ? At last thanks for you video. So much help. My unreal engine version was 4.25.4 by the way

  4. So if this will work on a local client ,meaning same computer, will it also work from another computer on the same home network, with port forwarding set to the pc running the dedicated server, and firewall exceptions on the pc running the server and the other network pc running the client version with the console command or does that actually have to be set up in the level blueprint to accept connection?

  5. We alluded to this at around 1:24 but please let us know by liking this comment or replying if you would be interested in a separate, more informational type video rather than a tutorial that goes over not just what dedicated servers are in general but also what other kinds of game servers are in general such as listen servers and comparing the pros and cons between them!

Leave a Reply

Your email address will not be published. Required fields are marked *