Unity and Dedicated Servers

The project I am working on would be best suited by a dedicated server for the multiplayer aspects of it. However, I am at a loss as to where to even begin. I’ve done network programming before but I do not know how I am suppose to load scene data into a console application for validating player movement and actions, projectile collisions, etc.

The only option I seem to be able to find is just creating a server instance of the game but that would be such a waste given that it would be rendering. If I were to put multiple instances on a single server it would waste so much processing power and memory.

So, my question is: how do I go about creating a dedicated server that has the map data for synchronizing map data (world objects animation etc), validating player movement and actions and minimizes cpu and memory usage? Is this built into unity? Are there tutorials for this (I have found none in my searching)?

I feel like it would be so much easier to be able to create all of this in unity and then just have a console version that does’t render anything to be the server but, again, I can’t seem to find a way to go about that. I am specifically targeting a server / client architecture.

Build in headless mode for linux, done

1 Like

Building in headless mode removes the rendering problem. I’m currently looking at the Headless Builder asset on the asset store which replaces referenced assets you wouldn’t actually use on the server with dummy assets to reduce CPU and memory usage further.

You could also probably use Experimental.PlayerLoop to disable native calls that you wouldn’t need. Definitely going to look into that when I have more time