flush tablist on connect
This commit is contained in:
parent
0d1fed30f5
commit
7b8a4eae5a
1 changed files with 5 additions and 1 deletions
|
@ -164,9 +164,13 @@ class Treepuncher(MinecraftClient):
|
|||
|
||||
def _register_handlers(self):
|
||||
@self.on_disconnected()
|
||||
async def on_disconnected():
|
||||
async def disconnected_cb():
|
||||
self.in_game = False
|
||||
|
||||
@self.on_connected()
|
||||
async def connected_cb():
|
||||
self.tablist = {}
|
||||
|
||||
@self.on_packet(PacketSetSlot)
|
||||
async def on_set_slot(packet:PacketSetSlot):
|
||||
if packet.windowId == 0: # player inventory
|
||||
|
|
Loading…
Reference in a new issue