   Handling physics over network (Multiplayer game)
  Hello GameDev's,lately i spend my time working on physics - for tests and fun.I have more than a basic experience in writing multiplayer games with client/server architecture and this is why i started to think of a simple multiplayer game with physics.There is one thing that somehow i cannot come up to - what are the stepsto follow when implementing physics on a network based game.Imagine a simple level, built with 4 walls like a Quad.Players fighting by shooting a 'bullet' with physics.How to handle the collisions, the trajectories etc..Am i thinking okay while saying that:Server keeps rotation / position of each playerServer runs physics engine ( collision callbacks etc.. )When player 'shoots' - it is the server to broadcast: direction of the bullet,speed of the bullet and other x,y,z... values.Server receives a collision callback, if this is other player - broadcast health decrement, if this is a wall - broadcast 'bullet destroy'.Will that work?PS. what should happen if a collision with something dynamic happens - i.e a wooden box, that should normally bounce somewhere when hit?   
  that's the standard procedure. If your bullet hit an object, the server will change the trajectory of the bullet, and on the next update broadcast, the bullet will be update on clients.Clients are 'dumb' and should not compute anything, (apart from their own prediction, which should have no effect on the game).See Gaffer On Networked Physics article, for client-side prediction / correction.http://gafferongames.com/game-physics/networked-physics/;  Great article,should help me sorting this all out.I'll come back with the results - as usual:)   ;  I started doing research on this stuff last week. Here's a collection of links I found really useful on the topic and will be looking over more:Quote:http://www.gamasutra.com/features/20010322/terrano_01.htmhttp://www.flipcode.com/archives/Main_Loop_with_Fixed_Time_Steps.shtmlhttp://gafferongames.com/game-physics/networked-physics/http://www.zoidcom.com/wiki/doku.php/newtonzoidcomhttp://gafferongames.com/game-physics/networked-physics/http://www.gamedev.net/community/forums/topic.asp?topic_id=450084http://www.hardforum.com/showthread.php?t=1119961http://gafferongames.com/2008/02/27/gdc-slides-released/http://www.gamedev.net/community/forums/topic.asp?topic_id=521371http://developer.nvidia.com/object/physx_tips.html#Networkhttp://www.cokeandcode.com/node/915http://www.newtondynamics.com/forum/viewtopic.php?f=9&t=4669http://ask.metafilter.com/113634/Learning-realtime-sound-event-synchronization-C-programminghttp://www.gamedev.net/community/forums/topic.asp?topic_id=433368https://blogs.msdn.com/shawnhar/archive/2008/01/01/network-compression-just-say-no.aspxhttp://developer.valvesoftware.com/wiki/Lag_Compensationhttp://www.brightland.com/Physics/index.htmhttp://opende.sourceforge.net/wiki/index.php/HOWTO_network_ODEhttp://www.thestudentroom.co.uk/showthread.php?t=625744http://www.gamasutra.com/features/19970919/aronson_01.htmhttp://www.opserver.de/ubb7/ubbthreads.php?ubb=showflat&Number=253758http://gmc.yoyogames.com/lofiversion/index.php/t415538.htmlhttp://www.usenix.org/event/iptps09/tech/full_papers/bai/bai_html/Cheers!   ;  Great stuff to have it all here!many thanks!Time to code!;]   ;  Just to clarify - i'm interested into "networking physics" - network coding itself is not a magic thing for me.[Edited by - dirtysanchez on April 27, 2009 10:06:33 AM]