Rearrange Link Play module

- Try to ensure thread safety by using TCP socket
This commit is contained in:
Lost-MSth
2022-09-19 01:46:01 +08:00
parent b1575af0db
commit 6298b37ea2
16 changed files with 387 additions and 310 deletions

View File

@@ -38,7 +38,12 @@ class Constant:
DOWNLOAD_LINK_PREFIX = Config.DOWNLOAD_LINK_PREFIX
LINK_PLAY_UNLOCK_LENGTH = 512 # Units: bytes
LINK_PLAY_TIMEOUT = 10 # Units: seconds
LINK_PLAY_TIMEOUT = 5 # Units: seconds
LINK_PLAY_HOST = '127.0.0.1' if Config.SET_LINK_PLAY_SERVER_AS_SUB_PROCESS else Config.LINK_PLAY_HOST
LINK_PLAY_TCP_PORT = Config.LINK_PLAY_TCP_PORT
LINK_PLAY_UDP_PORT = Config.LINK_PLAY_UDP_PORT
LINK_PLAY_AUTHENTICATION = Config.LINK_PLAY_AUTHENTICATION
COURSE_STAMINA_COST = 4