Who handles collision detection/response?

Started by
13 comments, last by SGreth 20 years, 3 months ago
quote:Original post by Taulin
Any time the client is allowed to make world state changes, it leads to cheating and stabability problems, much like a peer to peer network game works, and why most people choose client-server now.

The server should do world calculations like hit detection and such to keep the game world data accurate, and send out delta info. The client should do only the amount needed for prediction (i.e. starting with QuakeWorld). Again, it is good if you can let the client do some of the work, but be carefull of cheating.




interNEKO


Do you have any reccomendations as to how much processing the client should actually do? How laggy/appropriate would it be for the clients to only report delta''s in speed and orientation and then have the server relay that info to all other clients?
"The difference between insanity and genius is measured only by success."~Bruce Feirstein
Advertisement
The Torque handled it by using warps.

Both client and server ran the physics, the server would then send object "states" to the clients.

So, if there''s network lag, the client would keep the objects moving to their physical properties. If a player is falling in an arc from the last state update, then between state updates chances are its still falling in an arc.

When the state frame arrives to the client, then the client warps the objects to match the server state frame.
One important reason for having it server side. Bots, Patches, Hacks, Clones. If the collisions are client side, the client can be hacked to remove the collision detection.
william bubel
quote:Original post by SGreth
Do you have any reccomendations as to how much processing the client should actually do? How laggy/appropriate would it be for the clients to only report delta''s in speed and orientation and then have the server relay that info to all other clients?


Sorry, I didn''t mean it that way. The server reports deltas TO the client. It is important that the client recieves them though, so you might consider sending whole world states ever X seconds for full sync (depending on game,and importance priority).

Think of it this way. The client''s screen is a window to the server. The client''s controls are only inputs to the server.

As I said, and Inmate confirmed, anytime the client does calculations that change the real world state, you are opened for hacks.





interNEKO
quote:Original post by Taulin
quote:Original post by SGreth
Do you have any reccomendations as to how much processing the client should actually do? How laggy/appropriate would it be for the clients to only report delta''s in speed and orientation and then have the server relay that info to all other clients?


Sorry, I didn''t mean it that way. The server reports deltas TO the client. It is important that the client recieves them though, so you might consider sending whole world states ever X seconds for full sync (depending on game,and importance priority).

Think of it this way. The client''s screen is a window to the server. The client''s controls are only inputs to the server.

As I said, and Inmate confirmed, anytime the client does calculations that change the real world state, you are opened for hacks.


interNEKO

I follow you on that one. It sounds as though doing all collision on both the client and server is the best way to go. The server is the ''authoritative'' peer in the network though. The clients just do their own collision for the gaps where their interpolation of the objects last state says they hit something. When the server updates the object it can be warped back into place if it''s really out of sync.

Thanks!
"The difference between insanity and genius is measured only by success."~Bruce Feirstein

This topic is closed to new replies.

Advertisement