1
This commit is contained in:
parent
f21d04de3c
commit
4dec805ed7
@ -77,7 +77,7 @@ def readMysqlData(rushtime):
|
|||||||
alive_time = safeDiv(row[4], row[7])
|
alive_time = safeDiv(row[4], row[7])
|
||||||
harm = safeDiv(row[5], row[7])
|
harm = safeDiv(row[5], row[7])
|
||||||
win_times = safeDiv(row[6], row[7])
|
win_times = safeDiv(row[6], row[7])
|
||||||
array.append((row[0], row[1], row[2], kill, alive_time, harm, win_times, row[6]))
|
array.append((row[0], row[1].decode('utf-8'), row[2], kill, alive_time, harm, win_times, row[6]))
|
||||||
|
|
||||||
r = getRedis()
|
r = getRedis()
|
||||||
array.sort(key=take_kills, reverse=True)
|
array.sort(key=take_kills, reverse=True)
|
||||||
@ -126,7 +126,7 @@ if __name__ == "__main__":
|
|||||||
|
|
||||||
app = make_app()
|
app = make_app()
|
||||||
app.listen(conf['listen_port'])
|
app.listen(conf['listen_port'])
|
||||||
conf['rushtime'] = 300
|
conf['rushtime'] = 3
|
||||||
|
|
||||||
tornado.ioloop.IOLoop.current().call_later(conf['rushtime'],
|
tornado.ioloop.IOLoop.current().call_later(conf['rushtime'],
|
||||||
lambda : readMysqlData(conf['rushtime'])
|
lambda : readMysqlData(conf['rushtime'])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user