pep.py/events/tournamentMatchInfoRequestEvent.py

9 lines
339 B
Python
Raw Normal View History

from constants import clientPackets
from objects import glob
def handle(userToken, packetData):
packetData = clientPackets.tournamentMatchInfoRequest(packetData)
matchID = packetData["matchID"]
2017-08-07 21:53:09 +00:00
if matchID not in glob.matches.matches or not userToken.tournament:
return
userToken.enqueue(glob.matches.matches[matchID].matchDataCache)