so basically there are a few methods for spawning global impact effects in a multiplayer [shooter], impact effects are what you see when you or another player shoots an object, this is targetting dynamic objects on a network game however
first method - clientSide shot recreationin this method, when a player shoots, he sends that info, all players then retake the shot and create effects locally for that new shot, you also can send less data this way because you can just send a shot signal to players and they'll shoot accordingly
this isnt the fastest method however since youre running a trace for each shot also it only works best for static objects:
if a highpinger shoots a moving object/player he sees at position (50,50,10) then what happens is, by now that player would be at a different position on other clients, say (75,3,10) when the shot is recreated on their pcs, the effect fails because the traces hit nothing, you see the bullet impacting other surfaces yet you see someone die as shown in the pretty sketch, left side shows what the player that shoots sees, right image shows what other players see under lagged network conditions:
this is quite common in multiplayer games, too see bullet traces missing yet the player taking damage which leads us to
second method - positionBased creationin this method when a client shoots someone or something, he sends the position of where HE created that effect to everyone else, all other clients then spawn the effect on that position, that looks good in good network conditions, but if not, you'll see effects being spawned in the air when the object they supposedly hit has already moved:
and i know your thinking, why not just create the effects relative to the entity, which leads to the
last method:this also works ok under good conditions, i assume it needs to send a bit more data though, however under bad conditions, it may look weird when someone is being shot at, runs behind a wall, and you start seeing impacts created on him AFTER hes in cover, to be honest, i'm a bit scared of this one, i remember in gears of war where someone would run away from a sniper bullet, get into cover, then his head spontaneously pops because the bullet did actually hit on the client that fired it:
the second method seems like the more effective choice, netword conditions would have to be pretty horrible for it to look bad and i think i may combine it with the last method, i havent decided yet, so if you have a better solution in mind, let us know
i've also started a blog and would love your support:
http://scionwars.blog.com/