1 (edited by TigTex 2011-05-18 18:27:37)

Topic: Ping is FPS dependent

Maybe you already noticed that vsync is enabled by default and most of us have a lcd display with 60hz refresh rate.
What does it means? It means that you play teeworlds with 60 frames per second for perfect smooth gameplay.
Maybe you also noticed that if you host a game on your pc and you connect to your own server (localhost), your ping is always near 16-20ms.
The reason is simple... We have 60fps and that is 1/60 seconds (16,7ms). In every game you join, you will always have those extra 20ms of ping because that's the way teeworlds 0.6 works.
A workaround is to disable vsync. Instead of 60fps, you have 500fps for example. That means that your ping will change from 16 to 2ms (1/500).
Real life example. I used to play ctf5 on gv servers. With vsync I have 80ms of ping, without I have 59ms. Also if i play on my local server, my ping is 2-3ms instead of 20. (if I had 1000fps, i would have 1ms of ping).

A lot of games don't have this dependency between fps and latency... If you have 10 fps or 1000fps, your network will always respond as fast as possible (example... games with source engine).

We are talking about 20ms. It may not be a lot but in teeworlds every milisecond is crucial. If you have a low end pc, maybe you have less than 60fps, so the gains would be even bigger.

Isn't possible to change the way that teeworlds sends every network tick to a defined speed (for example 500 times per second) instead of beeing FPS dependent? That would improve teeworlds responsiveness and gameplay at a cost of a slightly more bandwidth usage.

Thank you for reading wink

.::. TigTex [PT] .::.

2 (edited by ghost 2011-05-18 18:31:08)

Re: Ping is FPS dependent

There is already a ticket about that on github: Issue #182.

//Edit:
You can also read there, that the shown ping is not really correct anyways. However, solving this issue would need a complete separation of the network stuff and the graphical stuff and that would require the use of threads wich will imply the heavy use of mutexes (locks) and similar stuff. This is a huge task, so it might not be done in the near future, as this issue is not very crucial.

3 (edited by heinrich5991 2011-05-18 18:28:13)

Re: Ping is FPS dependent

In my opinion it's enough to send packets 60 times a second - a human can't react faster. Though the visible ping changes with vsync on/off, the real ping isn't affected at all. In my opinion this isn't a problem. There is an issue on github though. #182

Edit: ghost was faster

4

Re: Ping is FPS dependent

ok, should have checked github first...sorry  tongue The "real ping" isn't affected. But the game responsiveness is. You can see the diference if you try to hook someone...

5

Re: Ping is FPS dependent

take a look at what I added to my post.

6 (edited by TigTex 2011-05-18 18:35:37)

Re: Ping is FPS dependent

Yes I know it would be hard to change this behaviour without making big changes... But still it was just a suggestion to improve this game a little.. developers should take a look at this someday in the future

7

Re: Ping is FPS dependent

The real ping is affected! For me it is about 10ms wink
I already explained why it is affected on github but as it was already said... i dont think that the ping shown in scoreboard is correct xD
But it is true that a normal human wont notice the difference and the screen with vsync looks much more smooth.

uptee - a simple web interface for hosting and maintaining teeworlds servers
teerace - a website gathering results of trusted Race-mod servers providing global ranking and statistics
*gV* rox ^^

8

Re: Ping is FPS dependent

Well, I do notice the difference. This is why I play with vsync off all the time.

9

Re: Ping is FPS dependent

Sushi Tee wrote:

The real ping is affected! For me it is about 10ms wink
But it is true that a normal human wont notice the difference and the screen with vsync looks much more smooth.

And who says that we are normal humans? big_smile

When you have a low ping like 20 you really feel these ~10ms
It isn't a bug but in other games there isn't such a ping change because you have vsync on wink

10

Re: Ping is FPS dependent

im playing with vsync off too wink

in other games the network stuff is seperated from the rest i guess wink
this isnt that kind of a big deal but needs major changes in code

uptee - a simple web interface for hosting and maintaining teeworlds servers
teerace - a website gathering results of trusted Race-mod servers providing global ranking and statistics
*gV* rox ^^