Add support for Minecraft 1.9.1 (protocol 108) and 1.9.2 (protocol 109).
This commit is contained in:
1 parent
e1626ea7e0
commit
5202b2e6df
2 files changed
+7
-3
No files matched your search
@@ -8,6 +8,8 @@ __version__ = "0.1.0"
|
|||||||
SUPPORTED_PROTOCOL_VERSIONS = (
|
SUPPORTED_PROTOCOL_VERSIONS = (
|
||||||
47,
|
47,
|
||||||
107,
|
107,
|
||||||
|
108,
|
||||||
|
109,
|
||||||
)
|
)
|
||||||
|
|
||||||
SUPPORTED_MINECRAFT_VERSIONS = {
|
SUPPORTED_MINECRAFT_VERSIONS = {
|
||||||
@@ -21,4 +23,6 @@ SUPPORTED_MINECRAFT_VERSIONS = {
|
|||||||
'1.8.7': 47,
|
'1.8.7': 47,
|
||||||
'1.8.8': 47,
|
'1.8.8': 47,
|
||||||
'1.9': 107,
|
'1.9': 107,
|
||||||
|
'1.9.1': 108,
|
||||||
|
'1.9.2': 109,
|
||||||
}
|
}
|
||||||
@@ -287,14 +287,14 @@ class JoinGamePacket(Packet):
|
|||||||
0x23 if context.protocol_version >= 107 else
|
0x23 if context.protocol_version >= 107 else
|
||||||
0x01)
|
0x01)
|
||||||
packet_name = "join game"
|
packet_name = "join game"
|
||||||
definition = [
|
get_definition = staticmethod(lambda context: [
|
||||||
{'entity_id': Integer},
|
{'entity_id': Integer},
|
||||||
{'game_mode': UnsignedByte},
|
{'game_mode': UnsignedByte},
|
||||||
{'dimension': Byte},
|
{'dimension': Integer if context.protocol_version >= 108 else Byte},
|
||||||
{'difficulty': UnsignedByte},
|
{'difficulty': UnsignedByte},
|
||||||
{'max_players': UnsignedByte},
|
{'max_players': UnsignedByte},
|
||||||
{'level_type': String},
|
{'level_type': String},
|
||||||
{'reduced_debug_info': Boolean}]
|
{'reduced_debug_info': Boolean}])
|
||||||
|
|
||||||
|
|
||||||
class ChatMessagePacket(Packet):
|
class ChatMessagePacket(Packet):
|
||||||
|
|||||||
Reference in new issue
Block a user