Jump to content
  • Advertisement
Sign in to follow this  
beebs1

Replication looks choppy?

This topic is 2472 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hiya,

I have an interesting problem I'm hoping someone can help with :)

I'm currently throttling position/oritentation replication packets to be sent by clients every 30th of a second (assuming they have moved). The movement of other players in the game appears noticably choppy, although their position is correct and not lagging behind the simulation.

If I adjust the throttling to much more than 30 replications a second, lower-spec client machines can become overwhelmed and their local simulation starts to lag considerably behind the correct state.

I think I need to implement some kind of dead-reckoning, and send less actual updates. Could anyone give their opinion on just how often each client should be replicating it's position to the server?

Any suggestions appreciated!

Thanks.

Share this post


Link to post
Share on other sites
Advertisement
You can either "forward extrapolate," where you move a character forward based on the last received position/direction (and maybe other positions/directions) and then attempt to hide the discrepancy when you get the next packet and you "guessed wrong." This shows characters more or less where they "are" but will "guess wrong" when characters turn/jump a lot.

Or you can "trail behind," when you don't move a character until you have a new movement target point, at which point you start moving the character towards that point. By the time the character gets to that point, the next point will likely come in, and the character will move towards that point. This will move characters along the exact path they "actually" take, but will lag behind by transmission time plus one turn/tick time.

Share this post


Link to post
Share on other sites
Thanks, I'll have to think about which of those will fit - extrapolating future position seems the most likely.

Could you venture a guess at how often actual replication packets need to be sent?

Currently, I can see from the packet dumps that with only 5 players moving in close proximity these position replications count for 95% or more of all packets. This adds up to thousands of packets in 30 seconds of gameplay, and I can't help feeling it's unnecessary.

Just wondering how infrequently I can get away with sending them smile.png

Thanks again.

[Edit]

Unrelated - does every member here now have a 'warn status' next to each post? It's a little disconcerting ;)

Share this post


Link to post
Share on other sites
Only members who need to be carefully monitored by moderators, and perhaps secret UAV cameras, get the Warning Status label.
(That does pretty much mean every member, of course!)

Seriously, though, Good-old Quake games ran okay at 10 updates per second. The Halo series does 15 or so IIRC. PC-based high-performance shooters like Unreal Tournament or Counter-Strike can go as high as you want to configure them -- some servers claim a rate of 60 per second. Personally, I think that's probably overkill for 99.9% of players :-)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!