Ralph and Networking


Ive made ralph with a small network and server.
How can i have 2 users see each other?

i know you would send your x,y,z to the server and then broadcast the coordinates to all clients. But isnt that gunna have alot of lag or anything?

Does anyone have any small examples i could see?

What you want to do is communicate any changes, so the clients and server communicate when velocity and rotation changes. The clients then make very accurate predictions on where all the avatars will be without needing constant coordinate updates from the server. It is a good idea for the server to give absolute positions every so often to keep everyone in sync.

Also doing constant coordinate updates would be more bandwidth intensive, not neccicarrally lag. Lag can come from any number of things, not just limited bandwidth.

im not sure how id do that…

Anyone have some examples?

Also how would i go about storing usernames via my server. atm it only stores connections.