Network: implement new packet: ConnectUpdate

This commit is contained in:
Fabian Dill
2021-11-01 20:00:55 +01:00
parent 0e0cc0ad16
commit e64d5c5f17
2 changed files with 10 additions and 3 deletions

View File

@@ -830,8 +830,7 @@ async def game_watcher(ctx: Context):
else:
ctx.tags -= {"DeathLink"}
if old_tags != ctx.tags and ctx.server and not ctx.server.socket.closed:
snes_logger.info("Forcing reconnect to set DeathLink state.")
await ctx.disconnect() # set correct tags
await ctx.send_msgs([{"cmd": "ConnectUpdate", "tags": ctx.tags}])
if not ctx.prev_rom or ctx.prev_rom != ctx.rom:
ctx.locations_checked = set()
ctx.locations_scouted = set()