pep.py/events/tournamentMatchInfoRequestEvent.py

9 lines
338 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"]
if matchID not in glob.matches.matches or not userToken.isTourney:
return
userToken.enqueue(glob.matches.matches[matchID].matchDataCache)