Forbid #spect_ and #multi_ manual join from game clients

This commit is contained in:
Giuseppe Guerra
2018-08-04 19:16:40 +02:00
parent 333cfca806
commit 7f283d9aa2
5 changed files with 42 additions and 20 deletions

View File

@@ -8,4 +8,4 @@ def handle(userToken, packetData):
if matchID not in glob.matches.matches or not userToken.tournament:
return
userToken.matchID = matchID
chat.joinChannel(token=userToken, channel="#multi_{}".format(matchID))
chat.joinChannel(token=userToken, channel="#multi_{}".format(matchID), force=True)

View File

@@ -7,5 +7,5 @@ def handle(userToken, packetData):
matchID = packetData["matchID"]
if matchID not in glob.matches.matches or not userToken.tournament:
return
chat.partChannel(token=userToken, channel="#multi_{}".format(matchID))
chat.partChannel(token=userToken, channel="#multi_{}".format(matchID), force=True)
userToken.matchID = 0