I would like to be able to fully utilize the ping that is provided by Roblox to be able to automatically replicate a certain set of important gameplay values with multiple clients and the server. As of now, it is very difficult to have information consistently sent both slow enough as to not overflow the remote queue, and fast enough as to not waste any network ticks without having sent any data. This can be very complicated and troublesome, especially if you’re trying to provide syncing for something such as someones VR hands, the aiming direction of their character in a shooter game, and their current movement inputs for something like client prediction.
It would be very useful to have something, that at the same time as physics replication, will be able to send and receive any updates to some sort of table or set of attributes without needing to manually replicate them or work around them. A simple example is I could share a table with all of the clients containing their current aiming and movement directions, and I could allow the client to make changes to only their respective table, in order to broadcast their own aiming directions. At the same time, we would need to have events that would listen to these changes, and respond. Preferably, a system much like this one:
--on the server function SyncEvent.OnServerInvoke( player: Player, latency: number, playerInformation ) if playerInformation then --read data and make changes to it if necessary --if data is bad, can reject it syncedData[player.UserId] = playerInformation return syncedData --returns a global state for broadcast end end) --on the client function SyncEvent.OnClientInvoke( latency: number, syncedData ) if syncedData then --perform some updates locally to match the server game state end return playerInformationLocal --return the local state in order to update the server state end)
It is assumed that these sync events will be invoked automatically when replication is occurring, and only if both the client and server have the sync event registered.
Both of these should also be executed AFTER physics and regular replication of values such as whether or not audio is playing, as this allows any of those changes to be reverted and revised.