stop faster

This commit is contained in:
əlemi 2021-11-29 03:50:33 +01:00
parent 5705cb4231
commit 934e00f112

View file

@ -188,7 +188,8 @@ class MinecraftClient(CallbacksHolder, Runnable):
await self.dispatcher.disconnect() await self.dispatcher.disconnect()
if not self.options.reconnect: if not self.options.reconnect:
break break
await asyncio.sleep(self.options.reconnect_delay) if self._processing: # if client was stopped exit immediately
await asyncio.sleep(self.options.reconnect_delay)
await self.stop(force=True) await self.stop(force=True)
async def _handshake(self) -> bool: # TODO make this fancier! poll for version and status first async def _handshake(self) -> bool: # TODO make this fancier! poll for version and status first