summaryrefslogtreecommitdiffstats
path: root/src/RankManager.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/RankManager.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/RankManager.cpp b/src/RankManager.cpp
index 0f267473a..fd5e58025 100644
--- a/src/RankManager.cpp
+++ b/src/RankManager.cpp
@@ -1817,6 +1817,25 @@ bool cRankManager::SetDefaultRank(const AString & a_RankName)
+void cRankManager::ClearPlayerRanks(void)
+{
+ ASSERT(m_IsInitialized);
+ cCSLock Lock(m_CS);
+
+ try {
+ SQLite::Statement stmt(m_DB, "DELETE FROM PlayerRank");
+ stmt.exec();
+ }
+ catch (SQLite::Exception & ex)
+ {
+ LOGWARNING("%s: Failed to remove/clear all players: %s", __FUNCTION__, ex.what());
+ }
+}
+
+
+
+
+
bool cRankManager::UpdatePlayerName(const AString & a_PlayerUUID, const AString & a_NewPlayerName)
{
ASSERT(m_IsInitialized);