how to sync bullet in online game?

Post Reply
khoowaikeong
Posts: 43
Joined: Fri Jun 15, 2012 7:11 am

how to sync bullet in online game?

Post by khoowaikeong »

is it hard? costly?

i setup a state system which allow the rigid bodies to react differently under certain condition (allow walk into wall and such), if the other client hasn't had that trigger updated before bullet does it step, the result will be different, should i then just overwrite the position to sync them?

so how do you guys do physic online? :)_
PgrAm
Posts: 12
Joined: Sun Apr 15, 2012 3:34 pm

Re: how to sync bullet in online game?

Post by PgrAm »

I would recommend doing physics on the server side it would simplify things allot and stop slower computers from affecting the game speed. If your multiplayer isn't server based then I would choose one player to "Host" the game and the physics would be done on their computer. The inputs from each client are sent to the host where it moves a character. After the physics are done on one computer its just a matter of sending the updated positions of objects to each client.
zerochen
Posts: 4
Joined: Fri Jun 01, 2012 3:21 pm

Re: how to sync bullet in online game?

Post by zerochen »

hi,

no i wouldn't recommend PgrAm way. have a look at this article
http://gafferongames.com/networking-for ... etworking/
Post Reply