- some minor fixes to non standard port display text

This commit is contained in:
Mark Vejvoda 2010-07-03 09:14:58 +00:00
parent 3b01eca7d7
commit ae8e8a71f2
2 changed files with 4 additions and 3 deletions

View File

@ -899,7 +899,7 @@ void MenuStateCustomGame::update() {
//SystemFlags::OutputDebug(SystemFlags::debugSystem,"In [%s::%s] C - ctNetwork\n",__FILE__,__FUNCTION__);
string port=intToStr(config.getInt("ServerPort"));
if(port!="61357"){
port=port +lang.get(" NonStandardPort")+"!";
port = port + " " + lang.get("NonStandardPort")+"!)";
}
else
{

View File

@ -448,10 +448,11 @@ void MenuStateMasterserver::updateServerInfo() {
masterServerInfo->setConnectedClients(strToInt(serverEntities[10]));
//printf("Getting Ping time for host %s\n",masterServerInfo->getIpAddress().c_str());
float pingTime = Socket::getAveragePingMS(masterServerInfo->getIpAddress().c_str(),1);
//float pingTime = Socket::getAveragePingMS(masterServerInfo->getIpAddress().c_str(),1);
//printf("Ping time = %f\n",pingTime);
char szBuf[1024]="";
sprintf(szBuf,"%s, %.2fms",masterServerInfo->getServerTitle().c_str(),pingTime);
//sprintf(szBuf,"%s, %.2fms",masterServerInfo->getServerTitle().c_str(),pingTime);
sprintf(szBuf,"%s",masterServerInfo->getServerTitle().c_str());
masterServerInfo->setServerTitle(szBuf);
if( updateFromMasterserverThread == NULL ||