Sign in to follow this  
Butabee

Server Frames Per Second

Recommended Posts

Butabee    274
If a server only needs to send out data and do all it's processing at an interval of once per second, is there any reason to try to get it to run faster than 1 "frame" per second? I think it would be good to leave some leeway for any needed burst processing, so maybe try to get it running an average of ~5 frames per second.

Share this post


Link to post
Share on other sites
Ashaman73    13715

With the assumption that you have build a reliable communication, you only need to send out data which have changed. So, if your data get only proceed once per second, you need to send them out once per second. With every frame just do

update data
check for modified data
send modified data
wait for next frame

Share this post


Link to post
Share on other sites
Butabee    274
It's a little more complicated in this case. I should have specified before but for a Unity server that handles physics I'm not sure I can do any waiting without it affecting the physics since Unity handles the threading, I wouldn't know where to put any stalls.

Share this post


Link to post
Share on other sites
Butabee    274

So it's pointless to wait it seems, since it just creates more work the next tick.

 

I mainly just want to process all physics entities within a second while supporting as many as I can. I don't think I need any artificial stalls.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this