mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 01:24:03 +02:00
Renamed getPingTime() to getPingMs() in Agent.h, etc.
This commit is contained in:
parent
0aa3227228
commit
a5c6cee433
3 changed files with 7 additions and 7 deletions
|
@ -2302,11 +2302,11 @@ void Application::displayStats() {
|
|||
Agent *voxelServerAgent = agentList->soloAgentOfType(AGENT_TYPE_VOXEL_SERVER);
|
||||
|
||||
if (audioMixerAgent != NULL)
|
||||
pingAudio = audioMixerAgent->getPingTime();
|
||||
pingAudio = audioMixerAgent->getPingMs();
|
||||
if (avatarMixerAgent != NULL)
|
||||
pingAvatar = avatarMixerAgent->getPingTime();
|
||||
pingAvatar = avatarMixerAgent->getPingMs();
|
||||
if (voxelServerAgent != NULL)
|
||||
pingVoxel = voxelServerAgent->getPingTime();
|
||||
pingVoxel = voxelServerAgent->getPingMs();
|
||||
|
||||
char pingStats[200];
|
||||
sprintf(pingStats, "Ping audio/avatar/voxel: %d / %d / %d ", pingAudio, pingAvatar, pingVoxel);
|
||||
|
|
|
@ -63,8 +63,8 @@ public:
|
|||
float getAverageKilobitsPerSecond();
|
||||
float getAveragePacketsPerSecond();
|
||||
|
||||
int getPingTime() { return _pingMs; };
|
||||
void setPingTime(int pingMs) { _pingMs = pingMs; };
|
||||
int getPingMs() const { return _pingMs; };
|
||||
void setPingMs(int pingMs) { _pingMs = pingMs; };
|
||||
|
||||
static void printLog(Agent const&);
|
||||
private:
|
||||
|
|
|
@ -80,9 +80,9 @@ AgentList::~AgentList() {
|
|||
void AgentList::timePingReply(sockaddr *agentAddress, unsigned char *packetData) {
|
||||
for(AgentList::iterator agent = begin(); agent != end(); agent++) {
|
||||
if (socketMatch(agent->getPublicSocket(), agentAddress) ||
|
||||
socketMatch(agent->getLocalSocket(), agentAddress)) {
|
||||
socketMatch(agent->getLocalSocket(), agentAddress)) {
|
||||
int pingTime = usecTimestampNow() - *(long long *)(packetData + 1);
|
||||
agent->setPingTime(pingTime / 1000);
|
||||
agent->setPingMs(pingTime / 1000);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue