mirror of
https://github.com/FAUSheppy/skillbird
synced 2025-12-06 06:51:34 +01:00
show only rank of active players etc
This commit is contained in:
@@ -84,7 +84,8 @@ def getPlayerRank(player):
|
|||||||
|
|
||||||
conn = sqlite3.connect("players.sqlite")
|
conn = sqlite3.connect("players.sqlite")
|
||||||
cursor = conn.cursor()
|
cursor = conn.cursor()
|
||||||
cursor.execute("SELECT COUNT(*) from players where (mu-2*sigma) > (?-2*?);",
|
cursor.execute('''SELECT COUNT(*) from players where (mu-2*sigma) > (?-2*?)
|
||||||
|
and not lastgame is null and games >= 10;''',
|
||||||
(player.rating.mu, player.rating.sigma))
|
(player.rating.mu, player.rating.sigma))
|
||||||
rank = cursor.fetchone()[0]
|
rank = cursor.fetchone()[0]
|
||||||
conn.close()
|
conn.close()
|
||||||
|
|||||||
Reference in New Issue
Block a user