mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 18:18:18 +00:00
Don't spam protect sql messages
This commit is contained in:
parent
2750a23792
commit
b0ae9d095f
|
@ -760,10 +760,10 @@ void CSqlScore::ShowTeamRankThread(void *pUser)
|
||||||
|
|
||||||
if(pData->m_pSqlData->m_pResults->getInt("stamp") != 0)
|
if(pData->m_pSqlData->m_pResults->getInt("stamp") != 0)
|
||||||
{
|
{
|
||||||
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, pData->m_ClientID);
|
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, -1);
|
||||||
str_format(aBuf, sizeof(aBuf), "Finished: %s ago", agoString);
|
str_format(aBuf, sizeof(aBuf), "Finished: %s ago", agoString);
|
||||||
}
|
}
|
||||||
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, pData->m_ClientID);
|
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, -1);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -939,10 +939,10 @@ void CSqlScore::ShowRankThread(void *pUser)
|
||||||
|
|
||||||
if(pData->m_pSqlData->m_pResults->getInt("stamp") != 0)
|
if(pData->m_pSqlData->m_pResults->getInt("stamp") != 0)
|
||||||
{
|
{
|
||||||
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, pData->m_ClientID);
|
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, -1);
|
||||||
str_format(aBuf, sizeof(aBuf), "Finished: %s ago", agoString);
|
str_format(aBuf, sizeof(aBuf), "Finished: %s ago", agoString);
|
||||||
}
|
}
|
||||||
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, pData->m_ClientID);
|
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, -1);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1359,7 +1359,7 @@ void CSqlScore::ShowPointsThread(void *pUser)
|
||||||
int count = (int)pData->m_pSqlData->m_pResults->getInt("Points");
|
int count = (int)pData->m_pSqlData->m_pResults->getInt("Points");
|
||||||
int rank = (int)pData->m_pSqlData->m_pResults->getInt("rank");
|
int rank = (int)pData->m_pSqlData->m_pResults->getInt("rank");
|
||||||
str_format(aBuf, sizeof(aBuf), "%d. %s Points: %d, requested by %s", rank, pData->m_pSqlData->m_pResults->getString("Name").c_str(), count, pData->m_aRequestingPlayer);
|
str_format(aBuf, sizeof(aBuf), "%d. %s Points: %d, requested by %s", rank, pData->m_pSqlData->m_pResults->getString("Name").c_str(), count, pData->m_aRequestingPlayer);
|
||||||
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, pData->m_ClientID);
|
pData->m_pSqlData->GameServer()->SendChat(-1, CGameContext::CHAT_ALL, aBuf, -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
dbg_msg("SQL", "Showing points done");
|
dbg_msg("SQL", "Showing points done");
|
||||||
|
|
Loading…
Reference in a new issue