How to sync / replicate material "TIME"?

Hi,

I have a very dynamic ocean material based on gerstner equations that I would like to sync between server and all connected clients.
The equations are generated using the material “time” node which I know starts at runtime and keeps increasing.

Basically what I want is when a client connects it should ask the server for it’s current “time” and then set that as the starting point for the client’s own “time”.

How do I achieve this?

Thanks.

Bump. Still need help with this.

Idea would be to ask the Server for his time (servers local time replicated to client), right on Startup of the Level.

Now take the Clients local time and ADD the server time substracted client time to it. this should result in:


client sync time = client time + (server time - client time)

you only need to ask for the server time once per opened level.

Thanks! That worked. :slight_smile:

I only applied the difference as an offset to the client’s own material time. Didn’t really need to have the actual outcome time. Just needed the offset.