Detect disconnection and exit the script
This commit is contained in:
@@ -447,3 +447,14 @@ class SelectTradePacket(Packet):
|
||||
definition = [
|
||||
{'selected_slot': VarInt},
|
||||
]
|
||||
|
||||
class DisconnectPacket(Packet):
|
||||
# Sent by the server before it disconnects a client
|
||||
# https://wiki.vg/Protocol#Disconnect_.28play.29
|
||||
|
||||
id = 0x19
|
||||
packet_name = 'disconnect'
|
||||
|
||||
definition = [
|
||||
{'reason': String},
|
||||
]
|
||||
|
Reference in New Issue
Block a user