Network: add RoomInfo -> Games

Allows clients to only download relevant parts of the datapackage, or to keep ID lookups per-game, and for Bounce to tell if there will be a receiving end.
This commit is contained in:
Fabian Dill
2021-10-22 04:46:00 +02:00
parent 0f4d285223
commit 8e35372aad
2 changed files with 7 additions and 5 deletions

View File

@@ -489,6 +489,7 @@ async def on_client_connected(ctx: Context, client: Client):
'cmd': 'RoomInfo',
'password': bool(ctx.password),
'players': players,
'games': [ctx.games[x] for x in range(1, len(ctx.games)+1)],
# tags are for additional features in the communication.
# Name them by feature or fork, as you feel is appropriate.
'tags': ctx.tags,