We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8de5e27 commit 7fb8624Copy full SHA for 7fb8624
1 file changed
valve/source/a2s.py
@@ -4,7 +4,7 @@
4
from __future__ import (absolute_import,
5
unicode_literals, print_function, division)
6
7
-import time
+import monotonic
8
9
import valve.source
10
from . import messages
@@ -64,10 +64,11 @@ def ping(self):
64
be negligble.
65
"""
66
67
- t_send = time.time()
+ time_sent = monontic.monotonic()
68
self.request(messages.InfoRequest())
69
messages.InfoResponse.decode(self.get_response())
70
- return (time.time() - t_send) * 1000.0
+ time_received = monotonic.monotonic()
71
+ return (time_received - t_sent) * 1000.0
72
73
def info(self):
74
"""Retreive information about the server state
0 commit comments