Create world as big as solar system

Hi,
I want to create a multiplayer space game with a size of ~ 1.000.000 x 1.000.000 x 1.000.000 km. The most of this world is empty.
To do that I already have a concept:
I divide the world in 20x20x20 km levels. I’m going to create only one empty level(-blueprint) for all levels together. The objects get spawned at the startup of the server. If one level doesn’t contain a object, the level shouldn’t get loaded.
The client should always load the 27 level (3x3x3 level), which are around him (except one of the surrounding levels are not loaded from the server, because they don’t contain a object).

The problem is that I only found two ideas how to do that and they are (I think) not really good:
1:
I create one master server, which can start, stop and change Level-Server. Every Level-Server has his own ID. The player always connect to the master server and transmit the IDs of the needed levels and then get forwarded to the right Level-Servers.
If one object leaves one level and get into another level, it should automatically get removed from the old server and should get add to the new server.

2:
I create one server, which contains all the levels. The players are joining to this server and are transmitting an ID. This ID determine, which level should be loaded on the client pc.

If one of these two ideas are useful, is the other problem that I don’t have a real idea how to program this with a good performance.

Can anyone give me a idea, how I could do this?

I can’t use world composition, because the position variable is only 32 bit and it can’t create such a size…

Your level sizes have to be much smaller then 20k for floating point accuracy, and while you can indeed create as many as you need and load them dynamically you’d have a horrid time trying to tile them up in world view. Plus, like you said the variable is out of range (because this is a pretty insane idea).

You are far better off faking it. Spaceship travel is usually static, and you fake the world moving around it in a procedural level.
You can refer to Mass Effect gameplay for some examples of how faking huge world spaces work too. Though it’s not exactly the same as traveling x years to pluto in real time.

If you need your users to be able to create waystations and such, the best approach would be to play with arrays.
Even then, when managing an array of so many entries you’d have a lot of issues/errors crop up, so you would need to drastically reduce the number of sectors to something more manageable.
Then you could perhaps duplicate the array and create a new “area” with the smaller working set.
However unreal isn’t very friendly to arrays in BP.

The sector subdivision is probably the way to go though.
Also, an empty level really has no “size”. Expecially if you use the world origin rebasing system to keep shifting the origin and addressing the issues with floating point precision.

It might be worth looking at how EVE Online does it. Essentially the star systems are massive but the only bits that actually exist are the bits that need to - generally an area of around 250km (not really modelled as km) around a player’s point of view, with everything in the player’s vicinity being ‘on-grid’. Everything outside of that ceases to exist until the player warps to a new spot, skipping over the empty space in between. The general idea is that the distances are so massive that you’re either effectively in one spot or travelling so fast that you can’t actually register any objects around you before they’re out of sight.