Loot (downloads/screenshots) is now sent by the teamserver either on client-connection or when new loot is added. For images, smaller thumbnails are used to reduce size of network packets.
This commit is contained in:
@@ -143,3 +143,12 @@ proc sendBuildlogItem*(client: WsConnection, logType: LogType, message: string)
|
||||
)
|
||||
if client != nil:
|
||||
client.ws.sendEvent(event, client.sessionKey)
|
||||
|
||||
proc sendLoot*(client: WsConnection, loot: LootItem) =
|
||||
let event = Event(
|
||||
eventType: CLIENT_LOOT_ADD,
|
||||
timestamp: now().toTime().toUnix(),
|
||||
data: %loot
|
||||
)
|
||||
if client != nil:
|
||||
client.ws.sendEvent(event, client.sessionKey)
|
||||
|
||||
Reference in New Issue
Block a user