This commit is contained in:
aozhiwei 2020-12-07 19:25:59 +08:00
parent 4d1302659b
commit da9c86495e

View File

@ -88,7 +88,10 @@ def _refreshData(row, data_list, data_info):
num = row[9]
if (time.time() > row[10]):
num = 0
data_list.append((row[0], row[1].decode('utf-8'), row[2], kill, alive_time, harm, win_times, row[6], num))
user_name = ''
if row[1]:
user_name = row[1].decode('utf-8')
data_list.append((row[0], user_name, row[2], kill, alive_time, harm, win_times, row[6], num))
data_list.sort(key=key_info, reverse=True)
if (len(data_list) > 50):
del data_list[50:]
@ -139,6 +142,8 @@ def fullUpdateRank():
for row in cursor:
has_data = True
last_idx = max(row[8], last_idx)
user_name = ''
if row[1]:
user_name = str(row[1], encoding='utf8')
if IGNORE_GUEST_ACCOUNT and (user_name == '游客' or user_name == '极乐玩家'):
continue
@ -208,6 +213,8 @@ def incrementUpdateRank():
has_data = True
channel = f7.getChannelByAccountId(row[0])
last_idx = max(row[8], last_idx)
user_name = ''
if row[1]:
user_name = str(row[1], encoding='utf8')
if IGNORE_GUEST_ACCOUNT and (user_name == '游客' or user_name == '极乐玩家'):
continue