PlaneShift
Support => Complaint Department => Topic started by: Volki on August 24, 2017, 09:08:00 pm
-
Why is there a % sign in the server ping on the login screen of the game?
It's been like this for as far as I can remember, but no one's ever commented on it. I'd like to know why it sometimes displays as a percentage when it's obviously not a percentage.
-
Not on mine. I'm running win64 version.
-
It will be related to packet loss. I saw a percentage often in times when the server was quite unstable and rebooted, so several pings remained unanswered. You can test it by temporarily disabling your network connection. The percent sign should probably be hidden until any loss actually happens.
-
If we look at the source code (https://sourceforge.net/p/planeshift/code/HEAD/tree/trunk/src/client/gui/pawsloginwindow.cpp) at client/gui/pawsloginwindow.cpp at function void pawsLoginWindow::Draw() we can see it indeed is package loss as LigH said. Here's mostly the relevant part of the code (starting from line 554)
void pawsLoginWindow::Draw()
{
// Check timeout
if(connecting && csGetTicks() >= timeout)
{
psengine->GetNetManager()->Disconnect();
ConnectionFailed();
PawsManager::GetSingleton().CreateWarningBox(PawsManager::GetSingleton().Translate("The server is not running or is not reachable. Please check the website or forums for more info."));
}
csString pingStr;
for (size_t i=0; i < servers.GetSize(); i++)
{
servers[i]->DoYourWork();
int ping = servers[i]->GetPing();
int loss = (int)(servers[i]->GetLoss()*100.0f);
switch (servers[i]->GetStatus())
{
case psServerPinger::INIT:
pingStr.Clear();
break;
case psServerPinger::FAILED:
pingStr = PawsManager::GetSingleton().Translate("Failed");
break;
case psServerPinger::FULL:
pingStr = PawsManager::GetSingleton().Translate("Full");
break;
case psServerPinger::READY:
if (loss == 100)
pingStr = PawsManager::GetSingleton().Translate("Failed");
else if (loss)
pingStr.Format("%d %d%%",ping,loss);
else
pingStr.Format("%d",ping);
break;
case psServerPinger::LOCKED:
pingStr = PawsManager::GetSingleton().Translate("Locked");
break;
case psServerPinger::WAIT:
pingStr = PawsManager::GetSingleton().Translate("Wait");
break;
default:
pingStr = PawsManager::GetSingleton().Translate("Error");
break;
}
listBox->SetTextCellValue((int)i, 2, pingStr);
}
pawsWidget::Draw();
}
-
So, what's the point of displaying it? No player should need to see that.
-
It's actually very usefull but not going too deep atm as i'm tired, but it can help people realize why they cant play well.
-
Packet loss can make moving characters in the world appear like jumping around (up to your client getting a warning by anti-cheat code discovering unusual acceleration, if that is still working at all), make you miss parts of a conversation, unexpectedly die in combat, even disconnect you more or less frequently.
Reasons can range from a faulty network adapter (or broken wires to it) in your PC, internet router, or even up to mis-routing or other node misconfiguration by your internet provider; or, if you play with a wireless connection, possibly heavy interferences caused by e.g. aged DECT phones or microwave ovens. Also there was a time, long ago, when the game server software acted weird.
Knowing such statistical numbers is surely useful if above mentioned issues happen to you.