danhin
Greetings VoxelFarmTorres,

We're currently using UE 4.16.2 with Visual Studio 2017 and version 3.1.0.1 of Voxel Farm.  We've had success with using the engine plugin running only as a client.  Now, we've reached a point in development where we can start on multiplayer.

I followed this tutorial for setting up a dedicated server build for our project:

https://wiki.unrealengine.com/Dedicated_Server_Guide_(Windows_%26_Linux)

After packaging the server and running it with the -log switch, the following error was logged in the terminal: Received None when accessing GetPlayerPawn.

I'm guessing that this is being thrown in the level blueprint where the scene focus is being set for the plugin.  I think that this can be fixed in the blueprint by only calling it as a client.

Before doing that, especially since a major release is coming, I'm looking for some guidance in using Voxel Farm in a client/server multiplayer model in UE.  The server will be running as a dedicated server that is spun up by an external service (in this case, GameLift hosted on AWS).  Generated terrain, as well as player edits (both deletions and additions), will need to be replicated from server to client.  Also, different server instances will need to synchronize this data to replicate to their clients.

I saw a very useful post on this forum about packaging as well.  Would this apply for packaging servers and clients?

As always, thank you for your support.
0 0
danhin
Hi,

I was able to get the plugin to work correctly with a Unreal Engine dedicated server running locally on my machine.  2 clients connected to the server via a loopback address, and both players were able to see one another on the same terrain.  With this in mind, I have some follow-up questions:

1.) Does data for procedural terrain and player edits replicate from server to client?

2.) Is it possible to serialize data for both procedural terrain and player edits?

3.) Is it possible to synchronize data for both procedural terrain and player edits?

In other words, could procedural terrain or player edits be generated on one server at a particular location in the game world (then replicated to the client for a player to see), then serialized to a shared data source, then loaded by another server for the same location in the game world to replicate to its clients?
0 0
voxelfarmtorres
1) Not at the moment. Replication must be performed by the application. If your model uses an authoritative server where all generation and edition happens, you can take a look at the ThinClient example in the SDK. This is not using UE, but it shows how clients can receive content from the server. In general, you would replace the local procedural and edition layers in the client by the remote voxel layer shown in the thin client example.

2) See answer above.

3) Yes, if your server is fully authoritative, you can send a message to the clients every time a cell is modified. The client in response would request these cells to be updated by calling processModifiedCells() into the clipmapview object:


Cells changedCells;
changedCells.insert(modifiedCells); // modifiedCells is a set of cells that changed from the server and are relevant to the client
TMap<CellId, CCellData::CInstanceEditionVolume> volumes;
clipmapView.processModifiedCells(changedCells, false, &volumes);



1 0