#Sending voxel data over the network with Netcode for Entities

1 messages · Page 1 of 1 (latest)

unique kayak
#

Hi! I am currently working on a voxel game using Unity's Data Oriented Tech Stack. I am currently in the process of porting my current systems to use client and server separation, and have started thinking about just how much data I am going to be sending over the network. My game uses 16x16x16 chunks and ushorts for block ids, which all adds up to 8,192 bytes of data for a single chunk. I do plan to have Run Length Encoding and LZ4 compression run on the data before transmission, but would also like to design my system to allow for additional metadata for blocks and to account for worst possible case scenario where the compression fails to make the data smaller (ex. someone builds some monstrosity where every single block within a chunk is unique). I was planning to send this data using RPCs, but after some research I've learned that RPCs may have an issue with this due to it being so much data. I was thinking maybe using multiple RPCs to send the data instead, but intuition tells me that I might run into a problem with sending hundreds of RPCs in a short timeframe. I was wondering if anyone else had experience with sending large amounts of data like this over Unity Transport and if anyone had recommendations on how to best proceed?

astral trout
#

My understanding from reading #1062393052863414313 is that entities is kind of a bad fit for voxel games. Your choices for loading entire chunks are limited. Ultimately I think you're gonna need smaller chunk sizes. But a file based approach might work better than shoving everything into RPCs or ghost components. At least for the initial load. Incremental changes could still be through RPCs. I'm just theorycrafting here, I've not done a networked voxel game before.