minecraft-data 3.26.0 → 3.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/data.js +43 -1
  2. package/doc/history.md +8 -0
  3. package/minecraft-data/README.md +1 -1
  4. package/minecraft-data/data/bedrock/1.16.201/proto.yml +1 -1
  5. package/minecraft-data/data/bedrock/1.16.201/protocol.json +1 -1
  6. package/minecraft-data/data/bedrock/1.16.210/proto.yml +1 -1
  7. package/minecraft-data/data/bedrock/1.16.210/protocol.json +1 -1
  8. package/minecraft-data/data/bedrock/1.16.220/proto.yml +1 -1
  9. package/minecraft-data/data/bedrock/1.16.220/protocol.json +1 -1
  10. package/minecraft-data/data/bedrock/1.17.0/proto.yml +1 -1
  11. package/minecraft-data/data/bedrock/1.17.0/protocol.json +1 -1
  12. package/minecraft-data/data/bedrock/1.17.10/proto.yml +1 -1
  13. package/minecraft-data/data/bedrock/1.17.10/protocol.json +1 -1
  14. package/minecraft-data/data/bedrock/1.17.30/proto.yml +1 -1
  15. package/minecraft-data/data/bedrock/1.17.30/protocol.json +1 -1
  16. package/minecraft-data/data/bedrock/1.17.40/proto.yml +1 -1
  17. package/minecraft-data/data/bedrock/1.17.40/protocol.json +1 -1
  18. package/minecraft-data/data/bedrock/1.18.0/proto.yml +1 -1
  19. package/minecraft-data/data/bedrock/1.18.0/protocol.json +1 -1
  20. package/minecraft-data/data/bedrock/1.18.11/proto.yml +1 -1
  21. package/minecraft-data/data/bedrock/1.18.11/protocol.json +1 -1
  22. package/minecraft-data/data/bedrock/1.18.30/proto.yml +1 -1
  23. package/minecraft-data/data/bedrock/1.18.30/protocol.json +1 -1
  24. package/minecraft-data/data/bedrock/1.19.1/proto.yml +1 -1
  25. package/minecraft-data/data/bedrock/1.19.1/protocol.json +1 -1
  26. package/minecraft-data/data/bedrock/1.19.10/proto.yml +1 -1
  27. package/minecraft-data/data/bedrock/1.19.10/protocol.json +1 -1
  28. package/minecraft-data/data/bedrock/1.19.20/proto.yml +1 -1
  29. package/minecraft-data/data/bedrock/1.19.20/protocol.json +1 -1
  30. package/minecraft-data/data/bedrock/1.19.21/proto.yml +1 -1
  31. package/minecraft-data/data/bedrock/1.19.21/protocol.json +1 -1
  32. package/minecraft-data/data/bedrock/1.19.30/proto.yml +1 -1
  33. package/minecraft-data/data/bedrock/1.19.30/protocol.json +1 -1
  34. package/minecraft-data/data/bedrock/1.19.40/proto.yml +1 -1
  35. package/minecraft-data/data/bedrock/1.19.40/protocol.json +1 -1
  36. package/minecraft-data/data/bedrock/1.19.50/proto.yml +3826 -0
  37. package/minecraft-data/data/bedrock/1.19.50/protocol.json +1 -1
  38. package/minecraft-data/data/bedrock/1.19.50/types.yml +2038 -0
  39. package/minecraft-data/data/bedrock/1.19.60/proto.yml +3850 -0
  40. package/minecraft-data/data/bedrock/1.19.60/protocol.json +11061 -0
  41. package/minecraft-data/data/bedrock/1.19.60/types.yml +2062 -0
  42. package/minecraft-data/data/bedrock/1.19.60/version.json +6 -0
  43. package/minecraft-data/data/bedrock/1.19.62/protocol.json +11065 -0
  44. package/minecraft-data/data/bedrock/1.19.62/version.json +6 -0
  45. package/minecraft-data/data/bedrock/common/protocolVersions.json +12 -0
  46. package/minecraft-data/data/bedrock/common/versions.json +3 -1
  47. package/minecraft-data/data/bedrock/latest/proto.yml +29 -5
  48. package/minecraft-data/data/bedrock/latest/types.yml +25 -0
  49. package/minecraft-data/data/dataPaths.json +43 -1
  50. package/minecraft-data/data/pc/1.19.3/protocol.json +21 -25
  51. package/minecraft-data/doc/history.md +7 -0
  52. package/package.json +1 -1
@@ -0,0 +1,3850 @@
1
+ # Created from MiNET and gophertunnel docs
2
+ # The version below is the latest version this protocol schema was updated for.
3
+ # The output protocol.json will be in the folder for the version
4
+ !version: 1.19.60
5
+
6
+ # Some ProtoDef aliases
7
+ string: ["pstring",{"countType":"varint"}] # String / array types
8
+ ByteArray: ["buffer",{"countType":"varint"}]
9
+ SignedByteArray: ["buffer",{"countType":"zigzag32"}]
10
+ LittleString: ["pstring",{"countType":"li32"}]
11
+ ShortArray: ["buffer",{"countType":"li16"}]
12
+ varint64: native # Some primitives
13
+ zigzag32: native
14
+ zigzag64: native
15
+ uuid: native # Data types & special handling
16
+ byterot: native
17
+ bitflags: native
18
+ restBuffer: native
19
+ encapsulated: native
20
+ nbt: native # NBT
21
+ lnbt: native
22
+ nbtLoop: native
23
+ enum_size_based_on_values_len: native # Packet-specific custom logic
24
+ MapInfo: native
25
+
26
+ # load the packet map file (auto-generated)
27
+ !import: packet_map.yml
28
+
29
+ !StartDocs: Packets
30
+
31
+ # # Login Sequence
32
+ # The login process is as follows:
33
+ #
34
+ # * C→S: [Login](#packet_login)
35
+ # * S→C: [Server To Client Handshake](#packet_server_to_client_handshake)
36
+ # * C→S: [Client To Server Handshake](#packet_client_to_server_handshake)
37
+ # * S→C: [Play Status (Login success)](#packet_play_status)
38
+ # * To spawn, the following packets should be sent, in order, after the ones above:
39
+ # * S→C: [Resource Packs Info](#packet_resource_packs_info)
40
+ # * C→S: [Resource Pack Client Response](#packet_resource_pack_client_response)
41
+ # * S→C: [Resource Pack Stack](#packet_resource_pack_stack)
42
+ # * C→S: [Resource Pack Client Response](#packet_resource_pack_client_response)
43
+ # * S→C: [Start Game](#packet_start_game)
44
+ # * S→C: [Creative Content](#packet_creative_content)
45
+ # * S→C: [Biome Definition List](#packet_biome_definition_list)
46
+ # * S→C: [Chunks](#packet_level_chunk)
47
+ # * S→C: [Play Status (Player spawn)](#packet_play_status)
48
+ #
49
+ # If there are no resource packs being sent, a Resource Pack Stack can be sent directly
50
+ # after Resource Packs Info to avoid the client responses.
51
+ #
52
+ # ===
53
+
54
+ packet_login:
55
+ !id: 0x01
56
+ !bound: server
57
+ # Protocol version (Big Endian!)
58
+ protocol_version: i32
59
+ tokens: '["encapsulated", { "lengthType": "varint", "type": "LoginTokens" }]'
60
+
61
+ LoginTokens:
62
+ # JSON array of JWT data: contains the display name, UUID and XUID
63
+ # It should be signed by the Mojang public key
64
+ identity: LittleString
65
+ # Skin related data
66
+ client: LittleString
67
+
68
+ packet_play_status:
69
+ !id: 0x02
70
+ !bound: client
71
+ status: i32 =>
72
+ # Sent after Login has been successfully decoded and the player has logged in
73
+ 0: login_success
74
+ # Displays "Could not connect: Outdated client!"
75
+ 1: failed_client
76
+ # Displays "Could not connect: Outdated server!"
77
+ 2: failed_spawn
78
+ # Sent after world data to spawn the player
79
+ 3: player_spawn
80
+ # Displays "Unable to connect to world. Your school does not have access to this server."
81
+ 4: failed_invalid_tenant
82
+ # Displays "The server is not running Minecraft: Education Edition. Failed to connect."
83
+ 5: failed_vanilla_edu
84
+ # Displays "The server is running an incompatible edition of Minecraft. Failed to connect."
85
+ 6: failed_edu_vanilla
86
+ # Displays "Wow this server is popular! Check back later to see if space opens up. Server Full"
87
+ 7: failed_server_full
88
+ # Cannot join a vanilla game on editor
89
+ 8: failed_editor_vanilla_mismatch
90
+ # Cannot join an editor game on vanilla
91
+ 9: failed_vanilla_editor_mismatch
92
+
93
+
94
+ packet_server_to_client_handshake:
95
+ !id: 0x03
96
+ !bound: client
97
+ # Contains the salt to complete the Diffie-Hellman key exchange
98
+ token: string
99
+
100
+
101
+ # Sent by the client in response to a Server To Client Handshake packet
102
+ # sent by the server. It is the first encrypted packet in the login handshake
103
+ # and serves as a confirmation that encryption is correctly initialized client side.
104
+ # It has no fields.
105
+ packet_client_to_server_handshake:
106
+ !id: 0x04
107
+ !bound: server
108
+
109
+ # Sent by the server to disconnect a client.
110
+ packet_disconnect:
111
+ !id: 0x05
112
+ !bound: client
113
+ # Specifies if the disconnection screen should be hidden when the client is disconnected,
114
+ # meaning it will be sent directly to the main menu.
115
+ hide_disconnect_reason: bool
116
+ # An optional message to show when disconnected.
117
+ message: string
118
+
119
+
120
+ packet_resource_packs_info:
121
+ !id: 0x06
122
+ !bound: client
123
+ # If the resource pack requires the client accept it.
124
+ must_accept: bool
125
+ # If scripting is enabled.
126
+ has_scripts: bool
127
+ # ForcingServerPacks is currently an unclear field.
128
+ force_server_packs: bool
129
+ # A list of behaviour packs that the client needs to download before joining the server.
130
+ # All of these behaviour packs will be applied together.
131
+ behaviour_packs: BehaviourPackInfos
132
+ # A list of resource packs that the client needs to download before joining the server.
133
+ # The order of these resource packs is not relevant in this packet. It is however important in the Resource Pack Stack packet.
134
+ texture_packs: TexturePackInfos
135
+
136
+ packet_resource_pack_stack:
137
+ !id: 0x07
138
+ !bound: client
139
+ # If the resource pack must be accepted for the player to join the server.
140
+ must_accept: bool
141
+ # [inline]
142
+ behavior_packs: ResourcePackIdVersions
143
+ # [inline]
144
+ resource_packs: ResourcePackIdVersions
145
+ game_version: string
146
+ experiments: Experiments # ??? such random fields
147
+ experiments_previously_used: bool
148
+
149
+ packet_resource_pack_client_response:
150
+ !id: 0x08
151
+ !bound: server
152
+ response_status: u8 =>
153
+ 0: none
154
+ 1: refused
155
+ 2: send_packs
156
+ 3: have_all_packs
157
+ 4: completed
158
+ # All of the pack IDs.
159
+ resourcepackids: ResourcePackIds
160
+
161
+ # Sent by the client to the server to send chat messages, and by the server to the client
162
+ # to forward or send messages, which may be chat, popups, tips etc.
163
+ ## https://github.com/pmmp/PocketMine-MP/blob/a43b46a93cb127f037c879b5d8c29cda251dd60c/src/pocketmine/network/mcpe/protocol/TextPacket.php
164
+ ## https://github.com/Sandertv/gophertunnel/blob/05ac3f843dd60d48b9ca0ab275cda8d9e85d8c43/minecraft/protocol/packet/text.go
165
+ packet_text:
166
+ !id: 0x09
167
+ !bound: both
168
+ # TextType is the type of the text sent. When a client sends this to the server, it should always be
169
+ # TextTypeChat. If the server sends it, it may be one of the other text types above.
170
+ type: u8 =>
171
+ 0: raw
172
+ 1: chat
173
+ 2: translation
174
+ 3: popup
175
+ 4: jukebox_popup
176
+ 5: tip
177
+ 6: system
178
+ 7: whisper
179
+ 8: announcement
180
+ 9: json_whisper
181
+ 10: json
182
+ 11: json_announcement
183
+ # NeedsTranslation specifies if any of the messages need to be translated. It seems that where % is found
184
+ # in translatable text types, these are translated regardless of this bool. Translatable text types
185
+ # include TextTypeTip, TextTypePopup and TextTypeJukeboxPopup.
186
+ needs_translation: bool
187
+ _: type?
188
+ if chat or whisper or announcement:
189
+ source_name: string
190
+ message: string
191
+ if raw or tip or system or json_whisper or json or json_announcement:
192
+ message: string
193
+ if translation or popup or jukebox_popup:
194
+ message: string
195
+ parameters: string[]varint
196
+ # The XUID of the player who sent this message.
197
+ xuid: string
198
+ # PlatformChatID is an identifier only set for particular platforms when chatting (presumably only for
199
+ # Nintendo Switch). It is otherwise an empty string, and is used to decide which players are able to
200
+ # chat with each other.
201
+ platform_chat_id: string
202
+ # For additional information and examples of all the chat types above, see here: https://imgur.com/a/KhcFscg
203
+
204
+
205
+ # Sent by the server to update the current time client-side. The client actually advances time
206
+ # client-side by itself, so this packet does not need to be sent each tick. It is merely a means
207
+ # of synchronizing time between server and client.
208
+ packet_set_time:
209
+ !id: 0x0a
210
+ !bound: client
211
+ # Time is the current time. The time is not limited to 24000 (time of day), but continues
212
+ # progressing after that.
213
+ time: zigzag32
214
+
215
+ # Sent by the server to send information about the world the player will be spawned in.
216
+ packet_start_game:
217
+ !id: 0x0b
218
+ !bound: client
219
+ # The unique ID of the player. The unique ID is a value that remains consistent across
220
+ # different sessions of the same world, but most unofficial servers simply fill the
221
+ # runtime ID of the entity out for this field.
222
+ entity_id: zigzag64
223
+ # The runtime ID of the player. The runtime ID is unique for each world session,
224
+ # and entities are generally identified in packets using this runtime ID.
225
+ runtime_entity_id: varint64
226
+ # PlayerGameMode is the game mode the player currently has. It is a value from 0-4, with 0 being
227
+ # survival mode, 1 being creative mode, 2 being adventure mode, 3 being survival spectator and 4 being
228
+ # creative spectator.
229
+ # This field may be set to 5 to make the client fall back to the game mode set in the WorldGameMode
230
+ # field.
231
+ player_gamemode: GameMode
232
+ # The spawn position of the player in the world. In servers this is often the same as the
233
+ # world's spawn position found below.
234
+ player_position: vec3f
235
+ # The pitch and yaw of the player
236
+ rotation: vec2f
237
+ # The seed used to generate the world.
238
+ seed: lu64
239
+ biome_type: li16
240
+ biome_name: string
241
+ # Dimension is the ID of the dimension that the player spawns in. It is a value from 0-2,
242
+ # with 0 being the overworld, 1 being the nether and 2 being the end.
243
+ dimension: zigzag32 =>
244
+ 0: overworld
245
+ 1: nether
246
+ 2: end
247
+ # Generator is the generator used for the world. It is a value from 0-4, with 0 being old
248
+ # limited worlds, 1 being infinite worlds, 2 being flat worlds, 3 being nether worlds and
249
+ # 4 being end worlds. A value of 0 will actually make the client stop rendering chunks you
250
+ # send beyond the world limit.
251
+ generator: zigzag32
252
+ # The world game mode that a player gets when it first spawns in the world. It is shown in the
253
+ # settings and is used if the Player Gamemode is set to 5.
254
+ world_gamemode: GameMode
255
+ # Difficulty is the difficulty of the world. It is a value from 0-3, with 0 being peaceful,
256
+ # 1 being easy, 2 being normal and 3 being hard.
257
+ difficulty: zigzag32
258
+ # The block on which the world spawn of the world. This coordinate has no effect on the place
259
+ # that the client spawns, but it does have an effect on the direction that a compass poInts.
260
+ spawn_position: BlockCoordinates
261
+ # Defines if achievements are disabled in the world. The client crashes if this value is set
262
+ # to true while the player's or the world's game mode is creative, and it's recommended to simply
263
+ # always set this to false as a server.
264
+ achievements_disabled: bool
265
+ # EditorWorld is a value to dictate if the world is in editor mode, a special mode recently introduced adding
266
+ # "powerful tools for editing worlds, intended for experienced creators."
267
+ editor_world: bool
268
+ # The time at which the day cycle was locked if the day cycle is disabled using the respective
269
+ # game rule. The client will maIntain this time as Boolean as the day cycle is disabled.
270
+ day_cycle_stop_time: zigzag32
271
+ # Some Minecraft: Education Edition field that specifies what 'region' the world was from,
272
+ # with 0 being None, 1 being RestOfWorld, and 2 being China. The actual use of this field is unknown.
273
+ edu_offer: zigzag32
274
+ # Specifies if the world has education edition features enabled, such as the blocks or entities
275
+ # specific to education edition.
276
+ edu_features_enabled: bool
277
+ edu_product_uuid: string
278
+ # The level specifying the Intensity of the rain falling. When set to 0, no rain falls at all.
279
+ rain_level: lf32
280
+ lightning_level: lf32
281
+ # The level specifying the Intensity of the thunder. This may actually be set independently
282
+ # from the rain level, meaning dark clouds can be produced without rain.
283
+ has_confirmed_platform_locked_content: bool
284
+ # Specifies if the world is a multi-player game. This should always be set to true for servers.
285
+ is_multiplayer: bool
286
+ # Specifies if LAN broadcast was Intended to be enabled for the world.
287
+ broadcast_to_lan: bool
288
+ # The mode used to broadcast the joined game across XBOX Live.
289
+ xbox_live_broadcast_mode: varint
290
+ # The mode used to broadcast the joined game across the platform.
291
+ platform_broadcast_mode: varint
292
+ # If commands are enabled for the player. It is recommended to always set this to true on the
293
+ # server, as setting it to false means the player cannot, under any circumstance, use a command.
294
+ enable_commands: bool
295
+ # Specifies if the texture pack the world might hold is required, meaning the client was
296
+ # forced to download it before joining.
297
+ is_texturepacks_required: bool
298
+ # Defines game rules currently active with their respective values. The value of these game
299
+ # rules may be either 'bool', 'Int32' or 'Float32'. Some game rules are server side only,
300
+ # and don't necessarily need to be sent to the client.
301
+ gamerules: GameRules
302
+ experiments: Experiments
303
+ experiments_previously_used: bool
304
+ # Specifies if the world had the bonus map setting enabled when generating it.
305
+ # It does not have any effect client-side.
306
+ bonus_chest: bool
307
+ # Specifies if the world has the start with map setting enabled, meaning each
308
+ # joining player obtains a map. This should always be set to false, because the
309
+ # client obtains a map all on its own accord if this is set to true.
310
+ map_enabled: bool
311
+ # The permission level of the player. It is a value from 0-3, with 0 being visitor,
312
+ # 1 being member, 2 being operator and 3 being custom.
313
+ permission_level: PermissionLevel
314
+ # The radius around the player in which chunks are ticked. Most servers set this value
315
+ # to a fixed number, as it does not necessarily affect anything client-side.
316
+ server_chunk_tick_range: li32
317
+ # Specifies if the texture pack of the world is locked, meaning it cannot be disabled
318
+ # from the world. This is typically set for worlds on the marketplace that have a dedicated
319
+ # texture pack.
320
+ has_locked_behavior_pack: bool
321
+ # Specifies if the texture pack of the world is locked, meaning it cannot be disabled from the
322
+ # world. This is typically set for worlds on the marketplace that have a dedicated texture pack.
323
+ has_locked_resource_pack: bool
324
+ # Specifies if the world from the server was from a locked world template.
325
+ # For servers this should always be set to false.
326
+ is_from_locked_world_template: bool
327
+ msa_gamertags_only: bool
328
+ # Specifies if the world from the server was from a locked world template.
329
+ # For servers this should always be set to false.
330
+ is_from_world_template: bool
331
+ # Specifies if the world was a template that locks all settings that change properties
332
+ # above in the settings GUI. It is recommended to set this to true for servers that
333
+ # do not allow things such as setting game rules through the GUI.
334
+ is_world_template_option_locked: bool
335
+ # A hack that Mojang put in place to preserve backwards compatibility with old villagers.
336
+ # The his never actually read though, so it has no functionality.
337
+ only_spawn_v1_villagers: bool
338
+ # PersonaDisabled is true if persona skins are disabled for the current game session.
339
+ persona_disabled: bool
340
+ # CustomSkinsDisabled is true if custom skins are disabled for the current game session.
341
+ custom_skins_disabled: bool
342
+ # EmoteChatMuted specifies if players will be sent a chat message when using certain emotes.
343
+ emote_chat_muted: bool
344
+ # The version of the game from which Vanilla features will be used.
345
+ # The exact function of this field isn't clear.
346
+ game_version: string
347
+ limited_world_width: li32
348
+ limited_world_length: li32
349
+ is_new_nether: bool
350
+ edu_resource_uri: EducationSharedResourceURI
351
+ experimental_gameplay_override: bool
352
+ # ChatRestrictionLevel specifies the level of restriction on in-game chat.
353
+ chat_restriction_level: u8 =>
354
+ 0: none
355
+ 1: dropped
356
+ 2: disabled
357
+ # DisablePlayerInteractions is true if the client should ignore other players when interacting with the world.
358
+ disable_player_interactions: bool
359
+ # A base64 encoded world ID that is used to identify the world.
360
+ level_id: string
361
+ # The name of the world that the player is joining. Note that this field shows up
362
+ # above the player list for the rest of the game session, and cannot be changed.
363
+ # Setting the server name to this field is recommended.
364
+ world_name: string
365
+ # A UUID specific to the premium world template that might have been used to
366
+ # generate the world. Servers should always fill out an empty String for this.
367
+ premium_world_template_id: string
368
+ # Specifies if the world was a trial world, meaning features are limited and there
369
+ # is a time limit on the world.
370
+ is_trial: bool
371
+
372
+ # MovementType specifies the way the server handles player movement. Available options are
373
+ # packet.AuthoritativeMovementModeClient, packet.AuthoritativeMovementModeServer and
374
+ # packet.AuthoritativeMovementModeServerWithRewind, where server the server authoritative types result
375
+ # in the client sending PlayerAuthInput packets instead of MovePlayer packets and the rewind mode
376
+ # requires sending the tick of movement and several actions.
377
+ #
378
+ # Specifies if the client or server is authoritative over the movement of the player,
379
+ # meaning it controls the movement of it.
380
+ ## https://github.com/pmmp/PocketMine-MP/blob/a43b46a93cb127f037c879b5d8c29cda251dd60c/src/pocketmine/network/mcpe/protocol/types/PlayerMovementType.php#L26
381
+ movement_authority: zigzag32 =>
382
+ 0: client
383
+ 1: server
384
+ # PlayerAuthInputPacket + a bunch of junk that solves a nonexisting problem
385
+ 2: server_with_rewind
386
+ # RewindHistorySize is the amount of history to keep at maximum if MovementType is
387
+ # packet.AuthoritativeMovementModeServerWithRewind.
388
+ rewind_history_size: zigzag32
389
+ # ServerAuthoritativeBlockBreaking specifies if block breaking should be sent through
390
+ # packet.PlayerAuthInput or not. This field is somewhat redundant as it is always enabled if
391
+ # MovementType is packet.AuthoritativeMovementModeServer or
392
+ # packet.AuthoritativeMovementModeServerWithRewind
393
+ server_authoritative_block_breaking: bool
394
+
395
+ # The total time in ticks that has elapsed since the start of the world.
396
+ current_tick: li64
397
+ # The seed used to seed the random used to produce enchantments in the enchantment table.
398
+ # Note that the exact correct random implementation must be used to produce the correct
399
+ # results both client- and server-side.
400
+ enchantment_seed: zigzag32
401
+
402
+ # BlockProperties is a list of all the custom blocks registered on the server.
403
+ block_properties: BlockProperties
404
+ # A list of all items with their legacy IDs which are available in the game.
405
+ # Failing to send any of the items that are in the game will crash mobile clients.
406
+ itemstates: Itemstates
407
+ # A unique ID specifying the multi-player session of the player.
408
+ # A random UUID should be filled out for this field.
409
+ multiplayer_correlation_id: string
410
+ # ServerAuthoritativeInventory specifies if the server authoritative inventory system is enabled. This
411
+ # is a new system introduced in 1.16. Backwards compatibility with the inventory transactions has to
412
+ # some extent been preserved, but will eventually be removed.
413
+ server_authoritative_inventory: bool
414
+ # The server's engine version, used for telemetry
415
+ engine: string
416
+ # PropertyData contains properties that should be applied on the player. These properties are the same as the
417
+ # ones that are sent in the SyncActorProperty packet.
418
+ property_data: nbt
419
+ # A checksum to ensure block types between the server and client match
420
+ block_pallette_checksum: lu64
421
+ # WorldTemplateID is a UUID that identifies the template that was used to generate the world. Servers that do not
422
+ # use a world based off of a template can set this to an empty UUID.
423
+ world_template_id: uuid
424
+ # ClientSideGeneration is true if the client should use the features registered in the FeatureRegistry packet to
425
+ # generate terrain client-side to save on bandwidth.
426
+ client_side_generation: bool
427
+
428
+ packet_add_player:
429
+ !id: 0x0c
430
+ !bound: client
431
+ # UUID is the UUID of the player. It is the same UUID that the client sent in the
432
+ # Login packet at the start of the session. A player with this UUID must exist
433
+ # in the player list (built up using the Player List packet) for it to show up in-game.
434
+ uuid: uuid
435
+ # Username is the name of the player. This username is the username that will be
436
+ # set as the initial name tag of the player.
437
+ username: string
438
+ # The runtime ID of the player. The runtime ID is unique for each world session,
439
+ # and entities are generally identified in packets using this runtime ID.
440
+ runtime_id: varint64
441
+ # An identifier only set for particular platforms when chatting (presumably only for
442
+ # Nintendo Switch). It is otherwise an empty string, and is used to decide which players
443
+ # are able to chat with each other.
444
+ platform_chat_id: string
445
+ # Position is the position to spawn the player on. If the player is on a distance that the viewer cannot
446
+ # see it, the player will still show up if the viewer moves closer.
447
+ position: vec3f
448
+ # Velocity is the initial velocity the player spawns with. This velocity will initiate client side
449
+ # movement of the player.
450
+ velocity: vec3f
451
+ # Pitch is the vertical rotation of the player. Facing straight forward yields a pitch of 0. Pitch is
452
+ # measured in degrees.
453
+ pitch: lf32
454
+ # Yaw is the horizontal rotation of the player. Yaw is also measured in degrees.
455
+ yaw: lf32
456
+ # HeadYaw is the same as Yaw, except that it applies specifically to the head of the player. A different
457
+ # value for HeadYaw than Yaw means that the player will have its head turned.
458
+ head_yaw: lf32
459
+ # HeldItem is the item that the player is holding. The item is shown to the viewer as soon as the player
460
+ # itself shows up. Needless to say that this field is rather pointless, as additional packets still must
461
+ # be sent for armour to show up.
462
+ held_item: Item
463
+ # GameType is the game type of the player. If set to GameTypeSpectator, the player will not be shown to viewers.
464
+ gamemode: GameMode
465
+ # EntityMetadata is a map of entity metadata, which includes flags and data properties that alter in
466
+ # particular the way the player looks. Flags include ones such as 'on fire' and 'sprinting'.
467
+ # The metadata values are indexed by their property key.
468
+ metadata: MetadataDictionary
469
+ # EntityProperties holds lists of entity properties that define specific attributes of an entity. As of v1.19.40, the
470
+ # vanilla server does not use these properties, however they are still supported by the protocol.
471
+ properties: EntityProperties
472
+ # The unique ID of the player. The unique ID is a value that remains consistent
473
+ # across different sessions of the same world, but most unoffical servers simply
474
+ # fill the runtime ID of the player out for this field.
475
+ unique_id: li64
476
+ permission_level: PermissionLevel
477
+ command_permission: CommandPermissionLevel
478
+ # AbilityLayer represents the abilities of a specific layer, such as the base layer or the spectator layer.
479
+ abilities: AbilityLayers[]u8
480
+ # EntityLinks is a list of entity links that are currently active on the player. These links alter the
481
+ # way the player shows up when first spawned in terms of it shown as riding an entity. Setting these
482
+ # links is important for new viewers to see the player is riding another entity.
483
+ links: Links
484
+ # DeviceID is the device ID set in one of the files found in the storage of the device of the player. It
485
+ # may be changed freely, so it should not be relied on for anything.
486
+ device_id: string
487
+ # BuildPlatform is the build platform/device OS of the player that is about to be added, as it sent in
488
+ # the Login packet when joining.
489
+ device_os: DeviceOS
490
+
491
+ packet_add_entity:
492
+ !id: 0x0d
493
+ !bound: client
494
+ # EntityUniqueID is the unique ID of the entity. The unique ID is a value that remains consistent across
495
+ # different sessions of the same world, but most servers simply fill the runtime ID of the entity out for
496
+ unique_id: zigzag64
497
+ # EntityRuntimeID is the runtime ID of the entity. The runtime ID is unique for each world session, and
498
+ # entities are generally identified in packets using this runtime ID.
499
+ runtime_id: varint64
500
+ # EntityType is the string entity type of the entity, for example 'minecraft:skeleton'. A list of these
501
+ # entities may be found online.
502
+ entity_type: string
503
+ # Position is the position to spawn the entity on. If the entity is on a distance that the player cannot
504
+ # see it, the entity will still show up if the player moves closer.
505
+ position: vec3f
506
+ # Velocity is the initial velocity the entity spawns with. This velocity will initiate client side
507
+ # movement of the entity.
508
+ velocity: vec3f
509
+ # Pitch is the vertical rotation of the entity. Facing straight forward yields a pitch of 0. Pitch is
510
+ # measured in degrees.
511
+ pitch: lf32
512
+ # Yaw is the horizontal rotation of the entity. Yaw is also measured in degrees.
513
+ yaw: lf32
514
+ # HeadYaw is the same as Yaw, except that it applies specifically to the head of the entity. A different value for
515
+ # HeadYaw than Yaw means that the entity will have its head turned.
516
+ head_yaw: lf32
517
+ # BodyYaw is the same as Yaw, except that it applies specifically to the body of the entity. A different value for
518
+ # BodyYaw than HeadYaw means that the entity will have its body turned, although it is unclear what the difference
519
+ # between BodyYaw and Yaw is.
520
+ body_yaw: lf32
521
+ # Attributes is a slice of attributes that the entity has. It includes attributes such as its health,
522
+ # movement speed, etc.
523
+ attributes: EntityAttributes
524
+ # EntityMetadata is a map of entity metadata, which includes flags and data properties that alter in
525
+ # particular the way the entity looks. Flags include ones such as 'on fire' and 'sprinting'.
526
+ # The metadata values are indexed by their property key.
527
+ metadata: MetadataDictionary
528
+ # EntityProperties holds lists of entity properties that define specific attributes of an entity. As of v1.19.40, the
529
+ # vanilla server does not use these properties, however they are still supported by the protocol.
530
+ properties: EntityProperties
531
+ # EntityLinks is a list of entity links that are currently active on the entity. These links alter the
532
+ # way the entity shows up when first spawned in terms of it shown as riding an entity. Setting these
533
+ # links is important for new viewers to see the entity is riding another entity.
534
+ links: Links
535
+
536
+ packet_remove_entity:
537
+ !id: 0x0e
538
+ !bound: client
539
+ entity_id_self: zigzag64
540
+
541
+ packet_add_item_entity:
542
+ !id: 0x0f
543
+ !bound: client
544
+ entity_id_self: zigzag64
545
+ runtime_entity_id: varint64
546
+ item: Item
547
+ position: vec3f
548
+ velocity: vec3f
549
+ metadata: MetadataDictionary
550
+ is_from_fishing: bool
551
+
552
+ packet_take_item_entity:
553
+ !id: 0x11
554
+ !bound: client
555
+ runtime_entity_id: varint64
556
+ target: varint
557
+
558
+ # MoveActorAbsolute is sent by the server to move an entity to an absolute position. It is typically used
559
+ # for movements where high accuracy isn't needed, such as for long range teleporting.
560
+ packet_move_entity:
561
+ !id: 0x12
562
+ !bound: both
563
+ # EntityRuntimeID is the runtime ID of the entity. The runtime ID is unique for each world session, and
564
+ # entities are generally identified in packets using this runtime ID.
565
+ runtime_entity_id: varint64
566
+ # Flags is a combination of flags that specify details of the movement. It is a combination of the flags
567
+ # above.
568
+ flags: u8
569
+ # Position is the position to spawn the entity on. If the entity is on a distance that the player cannot
570
+ # see it, the entity will still show up if the player moves closer.
571
+ position: vec3f
572
+ # Rotation is a Vec3 holding the X, Y and Z rotation of the entity after the movement. This is a Vec3 for
573
+ # the reason that projectiles like arrows don't have yaw/pitch, but do have roll.
574
+ rotation: Rotation
575
+
576
+ # MovePlayer is sent by players to send their movement to the server, and by the server to update the
577
+ # movement of player entities to other players.
578
+ packet_move_player:
579
+ !id: 0x13
580
+ !bound: both
581
+ # EntityRuntimeID is the runtime ID of the player. The runtime ID is unique for each world session, and
582
+ # entities are generally identified in packets using this runtime ID.
583
+ runtime_id: varint
584
+ # Position is the position to spawn the player on. If the player is on a distance that the viewer cannot
585
+ # see it, the player will still show up if the viewer moves closer.
586
+ position: vec3f
587
+ # Pitch is the vertical rotation of the player. Facing straight forward yields a pitch of 0. Pitch is
588
+ # measured in degrees.
589
+ pitch: lf32
590
+ # Yaw is the horizontal rotation of the player. Yaw is also measured in degrees
591
+ yaw: lf32
592
+ # HeadYaw is the same as Yaw, except that it applies specifically to the head of the player. A different
593
+ # value for HeadYaw than Yaw means that the player will have its head turned
594
+ head_yaw: lf32
595
+ # Mode is the mode of the movement. It specifies the way the player's movement should be shown to other
596
+ # players. It is one of the constants below.
597
+ mode: u8 =>
598
+ 0: normal
599
+ 1: reset
600
+ 2: teleport
601
+ 3: rotation
602
+ # OnGround specifies if the player is considered on the ground. Note that proxies or hacked clients could
603
+ # fake this to always be true, so it should not be taken for granted.
604
+ on_ground: bool
605
+ # RiddenEntityRuntimeID is the runtime ID of the entity that the player might currently be riding. If not
606
+ # riding, this should be left 0.
607
+ ridden_runtime_id: varint
608
+ teleport: mode ?
609
+ if teleport:
610
+ # TeleportCause is written only if Mode is MoveModeTeleport. It specifies the cause of the teleportation,
611
+ # which is one of the constants above.
612
+ cause: li32 =>
613
+ 0: unknown
614
+ 1: projectile
615
+ 2: chorus_fruit
616
+ 3: command
617
+ 4: behavior
618
+ # TeleportSourceEntityType is the entity type that caused the teleportation, for example an ender pearl.
619
+ # TODO: is this still a integer and not a string?
620
+ source_entity_type: LegacyEntityType
621
+ tick: varint64
622
+
623
+ packet_rider_jump:
624
+ !id: 0x14
625
+ !bound: both
626
+ jump_strength: zigzag32
627
+
628
+ # UpdateBlock is sent by the server to update a block client-side, without resending the entire chunk that
629
+ # the block is located in. It is particularly useful for small modifications like block breaking/placing.
630
+ packet_update_block:
631
+ !id: 0x15
632
+ !bound: client
633
+ # Position is the block position at which a block is updated.
634
+ position: BlockCoordinates
635
+ # NewBlockRuntimeID is the runtime ID of the block that is placed at Position after sending the packet
636
+ # to the client.
637
+ block_runtime_id: varint
638
+ # Flags is a combination of flags that specify the way the block is updated client-side. It is a
639
+ # combination of the flags above, but typically sending only the BlockUpdateNetwork flag is sufficient.
640
+ flags: UpdateBlockFlags
641
+ # Layer is the world layer on which the block is updated. For most blocks, this is the first layer, as
642
+ # that layer is the default layer to place blocks on, but for blocks inside of each other, this differs.
643
+ layer: varint
644
+
645
+
646
+ UpdateBlockFlags: [ "bitflags",
647
+ {
648
+ "type": "varint",
649
+ "flags": {
650
+ "neighbors": 1,
651
+ "network": 2,
652
+ "no_graphic": 0b100,
653
+ "unused": 0b1000,
654
+ "priority": 0b10000,
655
+ }
656
+ }
657
+ ]
658
+
659
+ packet_add_painting:
660
+ !id: 0x16
661
+ !bound: client
662
+ entity_id_self: zigzag64
663
+ runtime_entity_id: varint64
664
+ coordinates: vec3f
665
+ direction: zigzag32
666
+ title: string
667
+
668
+ # TickSync is sent by the client and the server to maintain a synchronized, server-authoritative tick between
669
+ # the client and the server. The client sends this packet first, and the server should reply with another one
670
+ # of these packets, including the response time.
671
+ packet_tick_sync:
672
+ !id: 0x17
673
+ !bound: both
674
+ # ClientRequestTimestamp is the timestamp on which the client sent this packet to the server. The server
675
+ # should fill out that same value when replying.
676
+ # The ClientRequestTimestamp is always 0
677
+ request_time: li64
678
+ # ServerReceptionTimestamp is the timestamp on which the server received the packet sent by the client.
679
+ # When the packet is sent by the client, this value is 0.
680
+ # ServerReceptionTimestamp is generally the current tick of the server. It isn't an actual timestamp, as
681
+ # the field implies
682
+ response_time: li64
683
+
684
+ packet_level_sound_event_old:
685
+ !id: 0x18
686
+ !bound: both
687
+ sound_id: u8
688
+ position: vec3f
689
+ block_id: zigzag32
690
+ entity_type: zigzag32
691
+ is_baby_mob: bool
692
+ is_global: bool
693
+
694
+ packet_level_event:
695
+ !id: 0x19
696
+ !bound: client
697
+ event: zigzag32 =>
698
+ 1000: sound_click
699
+ 1001: sound_click_fail
700
+ 1002: sound_shoot
701
+ 1003: sound_door
702
+ 1004: sound_fizz
703
+ 1005: sound_ignite
704
+ 1007: sound_ghast
705
+ 1008: sound_ghast_shoot
706
+ 1009: sound_blaze_shoot
707
+ 1010: sound_door_bump
708
+ 1012: sound_door_crash
709
+ 1018: sound_enderman_teleport
710
+ 1020: sound_anvil_break
711
+ 1021: sound_anvil_use
712
+ 1022: sound_anvil_fall
713
+ 1030: sound_pop
714
+ 1032: sound_portal
715
+ 1040: sound_itemframe_add_item
716
+ 1041: sound_itemframe_remove
717
+ 1042: sound_itemframe_place
718
+ 1043: sound_itemframe_remove_item
719
+ 1044: sound_itemframe_rotate_item
720
+ 1050: sound_camera
721
+ 1051: sound_orb
722
+ 1052: sound_totem
723
+ 1060: sound_armor_stand_break
724
+ 1061: sound_armor_stand_hit
725
+ 1062: sound_armor_stand_fall
726
+ 1063: sound_armor_stand_place
727
+ 1064: pointed_dripstone_land
728
+ 1065: dye_used
729
+ 1066: ink_sack_used
730
+ 2000: particle_shoot #TODO: check 2000-2017
731
+ 2001: particle_destroy
732
+ 2002: particle_splash
733
+ 2003: particle_eye_despawn
734
+ 2004: particle_spawn
735
+ 2005: particle_crop_growth
736
+ 2006: particle_guardian_curse
737
+ 2007: particle_death_smoke
738
+ 2008: particle_block_force_field
739
+ 2009: particle_projectile_hit
740
+ 2010: particle_dragon_egg_teleport
741
+ 2011: particle_crop_eaten
742
+ 2012: particle_critical
743
+ 2013: particle_enderman_teleport
744
+ 2014: particle_punch_block
745
+ 2015: particle_bubble
746
+ 2016: particle_evaporate
747
+ 2017: particle_destroy_armor_stand
748
+ 2018: particle_breaking_egg
749
+ 2019: particle_destroy_egg
750
+ 2020: particle_evaporate_water
751
+ 2021: particle_destroy_block_no_sound
752
+ 2022: particle_knockback_roar
753
+ 2023: particle_teleport_trail
754
+ 2024: particle_point_cloud
755
+ 2025: particle_explosion
756
+ 2026: particle_block_explosion
757
+ 2027: particle_vibration_signal
758
+ 2028: particle_dripstone_drip
759
+ 2029: particle_fizz_effect
760
+ 2030: particle_wax_on
761
+ 2031: particle_wax_off
762
+ 2032: particle_scrape
763
+ 2033: particle_electric_spark
764
+ 2034: particle_turtle_egg
765
+ 2035: particle_sculk_shriek
766
+ 2036: sculk_catalyst_bloom
767
+ 2037: sculk_charge
768
+ 2038: sculk_charge_pop
769
+ 2039: sonic_explosion
770
+
771
+ 3001: start_rain
772
+ 3002: start_thunder
773
+ 3003: stop_rain
774
+ 3004: stop_thunder
775
+ 3005: pause_game #data: 1 to pause, 0 to resume
776
+ 3006: pause_game_no_screen #data: 1 to pause, 0 to resume - same effect as normal pause but without screen
777
+ 3007: set_game_speed #x coordinate of pos = scale factor (default 1.0)
778
+ 3500: redstone_trigger
779
+ 3501: cauldron_explode
780
+ 3502: cauldron_dye_armor
781
+ 3503: cauldron_clean_armor
782
+ 3504: cauldron_fill_potion
783
+ 3505: cauldron_take_potion
784
+ 3506: cauldron_fill_water
785
+ 3507: cauldron_take_water
786
+ 3508: cauldron_add_dye
787
+ 3509: cauldron_clean_banner
788
+ 3600: block_start_break
789
+ 3601: block_stop_break
790
+ 4000: set_data
791
+ 9800: players_sleeping
792
+ 9801: sleeping_players
793
+ 0x4000: add_particle_mask
794
+ # 0x4000 | + particle ID
795
+ 16385: add_particle_bubble # 1
796
+ 16386: add_particle_bubble_manual # 2
797
+ 16387: add_particle_critical # 3
798
+ 16388: add_particle_block_force_field # 4
799
+ 16389: add_particle_smoke # 5
800
+ 16390: add_particle_explode # 6
801
+ 16391: add_particle_evaporation # 7
802
+ 16392: add_particle_flame # 8
803
+ 16393: add_particle_candle_flame # 9
804
+ 16394: add_particle_lava # 10
805
+ 16395: add_particle_large_smoke # 11
806
+ 16396: add_particle_redstone # 12
807
+ 16397: add_particle_rising_red_dust # 13
808
+ 16398: add_particle_item_break # 14
809
+ 16399: add_particle_snowball_poof # 15
810
+ 16400: add_particle_huge_explode # 16
811
+ 16401: add_particle_huge_explode_seed # 17
812
+ 16402: add_particle_mob_flame # 18
813
+ 16403: add_particle_heart # 19
814
+ 16404: add_particle_terrain # 20
815
+ 16405: add_particle_town_aura # 21
816
+ 16406: add_particle_portal # 22
817
+ 16408: add_particle_water_splash # 24
818
+ 16409: add_particle_water_splash_manual # 25
819
+ 16410: add_particle_water_wake # 26
820
+ 16411: add_particle_drip_water # 27
821
+ 16412: add_particle_drip_lava # 28
822
+ 16413: add_particle_drip_honey # 29
823
+ 16414: add_particle_stalactite_drip_water # 30
824
+ 16415: add_particle_stalactite_drip_lava # 31
825
+ 16416: add_particle_falling_dust # 32
826
+ 16417: add_particle_mob_spell # 33
827
+ 16418: add_particle_mob_spell_ambient # 34
828
+ 16419: add_particle_mob_spell_instantaneous # 35
829
+ 16420: add_particle_ink # 36
830
+ 16421: add_particle_slime # 37
831
+ 16422: add_particle_rain_splash # 38
832
+ 16423: add_particle_villager_angry # 39
833
+ 16424: add_particle_villager_happy # 40
834
+ 16425: add_particle_enchantment_table # 41
835
+ 16426: add_particle_tracking_emitter # 42
836
+ 16427: add_particle_note # 43
837
+ 16428: add_particle_witch_spell # 44
838
+ 16429: add_particle_carrot # 45
839
+ 16430: add_particle_mob_appearance # 46
840
+ 16431: add_particle_end_rod # 47
841
+ 16432: add_particle_dragons_breath # 48
842
+ 16433: add_particle_spit # 49
843
+ 16434: add_particle_totem # 50
844
+ 16435: add_particle_food # 51
845
+ 16436: add_particle_fireworks_starter # 52
846
+ 16437: add_particle_fireworks_spark # 53
847
+ 16438: add_particle_fireworks_overlay # 54
848
+ 16439: add_particle_balloon_gas # 55
849
+ 16440: add_particle_colored_flame # 56
850
+ 16441: add_particle_sparkler # 57
851
+ 16442: add_particle_conduit # 58
852
+ 16443: add_particle_bubble_column_up # 59
853
+ 16444: add_particle_bubble_column_down # 60
854
+ 16445: add_particle_sneeze # 61
855
+ 16446: add_particle_shulker_bullet # 62
856
+ 16447: add_particle_bleach # 63
857
+ 16448: add_particle_dragon_destroy_block # 64
858
+ 16449: add_particle_mycelium_dust # 65
859
+ 16450: add_particle_falling_red_dust # 66
860
+ 16451: add_particle_campfire_smoke # 67
861
+ 16452: add_particle_tall_campfire_smoke # 68
862
+ 16453: add_particle_dragon_breath_fire # 69
863
+ 16454: add_particle_dragon_breath_trail # 70
864
+ 16455: add_particle_blue_flame # 71
865
+ 16456: add_particle_soul # 72
866
+ 16457: add_particle_obsidian_tear # 73
867
+ 16458: add_particle_portal_reverse # 74
868
+ 16459: add_particle_snowflake # 75
869
+ 16460: add_particle_vibration_signal # 76
870
+ 16461: add_particle_sculk_sensor_redstone # 77
871
+ 16462: add_particle_spore_blossom_shower # 78
872
+ 16463: add_particle_spore_blossom_ambient # 79
873
+ 16464: add_particle_wax # 80
874
+ 16465: add_particle_electric_spark # 81
875
+ position: vec3f
876
+ data: zigzag32
877
+
878
+ packet_block_event:
879
+ !id: 0x1a
880
+ !bound: client
881
+ # Position is the position of the block that an event occurred at.
882
+ position: BlockCoordinates
883
+ # EventType is the type of the block event.
884
+ # The event type decides the way the event data that follows is used
885
+ type: zigzag32 =>
886
+ 0: sound
887
+ 1: change_state
888
+ # EventData holds event type specific data. For chests for example,
889
+ # opening the chest means the data must be 1
890
+ data: zigzag32
891
+
892
+ packet_entity_event:
893
+ !id: 0x1b
894
+ !bound: both
895
+ runtime_entity_id: varint64
896
+ event_id: u8 =>
897
+ 1: jump
898
+ 2: hurt_animation
899
+ 3: death_animation
900
+ 4: arm_swing
901
+ 5: stop_attack
902
+ 6: tame_fail
903
+ 7: tame_success
904
+ 8: shake_wet
905
+ 9: use_item
906
+ 10: eat_grass_animation
907
+ 11: fish_hook_bubble
908
+ 12: fish_hook_position
909
+ 13: fish_hook_hook
910
+ 14: fish_hook_tease
911
+ 15: squid_ink_cloud
912
+ 16: zombie_villager_cure
913
+ 18: respawn
914
+ 19: iron_golem_offer_flower
915
+ 20: iron_golem_withdraw_flower
916
+ 21: love_particles #breeding
917
+ 22: villager_angry
918
+ 23: villager_happy
919
+ 24: witch_spell_particles
920
+ 25: firework_particles
921
+ 26: in_love_particles
922
+ 27: silverfish_spawn_animation
923
+ 28: guardian_attack
924
+ 29: witch_drink_potion
925
+ 30: witch_throw_potion
926
+ 31: minecart_tnt_prime_fuse
927
+ 32: creeper_prime_fuse
928
+ 33: air_supply_expired
929
+ 34: player_add_xp_levels
930
+ 35: elder_guardian_curse
931
+ 36: agent_arm_swing
932
+ 37: ender_dragon_death
933
+ 38: dust_particles #not sure what this is
934
+ 39: arrow_shake
935
+
936
+ 57: eating_item
937
+
938
+ 60: baby_animal_feed #green particles, like bonemeal on crops
939
+ 61: death_smoke_cloud
940
+ 62: complete_trade
941
+ 63: remove_leash #data 1 = cut leash
942
+ 64: caravan
943
+ 65: consume_totem
944
+ 66: player_check_treasure_hunter_achievement #mojang...
945
+ 67: entity_spawn #used for MinecraftEventing stuff, not needed
946
+ 68: dragon_puke #they call this puke particles
947
+ 69: item_entity_merge
948
+ 70: start_swim
949
+ 71: balloon_pop
950
+ 72: treasure_hunt
951
+ 73: agent_summon
952
+ 74: charged_crossbow
953
+ 75: fall
954
+ 76: grow_up
955
+ 77: vibration_detected
956
+ 78: drink_milk
957
+ data: zigzag32
958
+
959
+ packet_mob_effect:
960
+ !id: 0x1c
961
+ !bound: client
962
+ runtime_entity_id: varint64
963
+ event_id: u8
964
+ effect_id: zigzag32
965
+ amplifier: zigzag32
966
+ particles: bool
967
+ duration: zigzag32
968
+
969
+ packet_update_attributes:
970
+ !id: 0x1d
971
+ !bound: client
972
+ runtime_entity_id: varint64
973
+ attributes: PlayerAttributes
974
+ tick: varint64
975
+
976
+ # InventoryTransaction is a packet sent by the client. It essentially exists out of multiple sub-packets,
977
+ # each of which have something to do with the inventory in one way or another. Some of these sub-packets
978
+ # directly relate to the inventory, others relate to interaction with the world, that could potentially
979
+ # result in a change in the inventory.
980
+ packet_inventory_transaction:
981
+ !id: 0x1e
982
+ !bound: both
983
+ transaction: Transaction
984
+
985
+ packet_mob_equipment:
986
+ !id: 0x1f
987
+ !bound: both
988
+ runtime_entity_id: varint64
989
+ item: Item
990
+ slot: u8
991
+ selected_slot: u8
992
+ window_id: WindowID
993
+
994
+ packet_mob_armor_equipment:
995
+ !id: 0x20
996
+ !bound: both
997
+ runtime_entity_id: varint64
998
+ helmet: Item
999
+ chestplate: Item
1000
+ leggings: Item
1001
+ boots: Item
1002
+
1003
+ # Interact is sent by the client when it interacts with another entity in some way. It used to be used for
1004
+ # normal entity and block interaction, but this is no longer the case now.
1005
+ packet_interact:
1006
+ !id: 0x21
1007
+ !bound: both
1008
+ # Action type is the ID of the action that was executed by the player. It is one of the constants that
1009
+ # may be found above.
1010
+ action_id: u8 =>
1011
+ 3: leave_vehicle
1012
+ 4: mouse_over_entity
1013
+ 6: open_inventory
1014
+ # TargetEntityRuntimeID is the runtime ID of the entity that the player interacted with. This is empty
1015
+ # for the InteractActionOpenInventory action type.
1016
+ target_entity_id: varint64
1017
+ # Position associated with the ActionType above. For the InteractActionMouseOverEntity, this is the
1018
+ # position relative to the entity moused over over which the player hovered with its mouse/touch. For the
1019
+ # InteractActionLeaveVehicle, this is the position that the player spawns at after leaving the vehicle.
1020
+ position: action_id ?
1021
+ if mouse_over_entity or leave_vehicle: vec3f
1022
+
1023
+ packet_block_pick_request:
1024
+ !id: 0x22
1025
+ !bound: server
1026
+ x: zigzag32
1027
+ y: zigzag32
1028
+ z: zigzag32
1029
+ add_user_data: bool
1030
+ selected_slot: u8
1031
+
1032
+ packet_entity_pick_request:
1033
+ !id: 0x23
1034
+ !bound: server
1035
+ runtime_entity_id: lu64
1036
+ selected_slot: u8
1037
+ # WithData is true if the pick request requests the entity metadata.
1038
+ with_data: bool
1039
+
1040
+ # PlayerAction is sent by the client when it executes any action, for example starting to sprint, swim,
1041
+ # starting the breaking of a block, dropping an item, etc.
1042
+ packet_player_action:
1043
+ !id: 0x24
1044
+ !bound: server
1045
+ # EntityRuntimeID is the runtime ID of the player. The runtime ID is unique for each world session, and
1046
+ # entities are generally identified in packets using this runtime ID.
1047
+ runtime_entity_id: varint64
1048
+ # ActionType is the ID of the action that was executed by the player. It is one of the constants that may
1049
+ # be found above.
1050
+ action: Action
1051
+ # BlockPosition is the position of the target block, if the action with the ActionType set concerned a
1052
+ # block. If that is not the case, the block position will be zero.
1053
+ position: BlockCoordinates
1054
+ # ResultPosition is the position of the action's result. When a UseItemOn action is sent, this is the position of
1055
+ # the block clicked, but when a block is placed, this is the position at which the block will be placed.
1056
+ result_position: BlockCoordinates
1057
+ # BlockFace is the face of the target block that was touched. If the action with the ActionType set
1058
+ # concerned a block. If not, the face is always 0.
1059
+ face: zigzag32
1060
+
1061
+ packet_hurt_armor:
1062
+ !id: 0x26
1063
+ !bound: client
1064
+ cause: zigzag32
1065
+ damage: zigzag32
1066
+ armor_slots: zigzag64
1067
+
1068
+ packet_set_entity_data:
1069
+ !id: 0x27
1070
+ !bound: both
1071
+ runtime_entity_id: varint64
1072
+ metadata: MetadataDictionary
1073
+ # EntityProperties holds lists of entity properties that define specific attributes of an entity. As of v1.19.40, the
1074
+ # vanilla server does not use these properties, however they are still supported by the protocol.
1075
+ properties: EntityProperties
1076
+ tick: varint64
1077
+
1078
+ # SetActorMotion is sent by the server to change the client-side velocity of an entity. It is usually used
1079
+ # in combination with server-side movement calculation.
1080
+ packet_set_entity_motion:
1081
+ !id: 0x28
1082
+ !bound: both
1083
+ # EntityRuntimeID is the runtime ID of the entity. The runtime ID is unique for each world session, and
1084
+ # entities are generally identified in packets using this runtime ID.
1085
+ runtime_entity_id: varint64
1086
+ # Velocity is the new velocity the entity gets. This velocity will initiate the client-side movement of
1087
+ # the entity.
1088
+ velocity: vec3f
1089
+
1090
+ # SetActorLink is sent by the server to initiate an entity link client-side, meaning one entity will start
1091
+ # riding another.
1092
+ packet_set_entity_link:
1093
+ !id: 0x29
1094
+ !bound: client
1095
+ link: Link
1096
+
1097
+ packet_set_health:
1098
+ !id: 0x2a
1099
+ !bound: client
1100
+ health: zigzag32
1101
+
1102
+ packet_set_spawn_position:
1103
+ !id: 0x2b
1104
+ !bound: client
1105
+ spawn_type: zigzag32 =>
1106
+ 0: player
1107
+ 1: world
1108
+ player_position: BlockCoordinates
1109
+ dimension: zigzag32
1110
+ world_position: BlockCoordinates
1111
+
1112
+ packet_animate:
1113
+ !id: 0x2c
1114
+ !bound: both
1115
+ action_id: zigzag32 =>
1116
+ 0: none
1117
+ 1: swing_arm
1118
+ 2: unknown
1119
+ 3: wake_up
1120
+ 4: critical_hit
1121
+ 5: magic_critical_hit
1122
+ 128: row_right
1123
+ 129: row_left
1124
+ runtime_entity_id: varint64
1125
+ _: action_id ?
1126
+ if row_right or row_left:
1127
+ boat_rowing_time: lf32
1128
+
1129
+ packet_respawn:
1130
+ !id: 0x2d
1131
+ !bound: both
1132
+ position: vec3f
1133
+ state: u8
1134
+ runtime_entity_id: varint64
1135
+
1136
+ # ContainerOpen is sent by the server to open a container client-side. This container must be physically
1137
+ # present in the world, for the packet to have any effect. Unlike Java Edition, Bedrock Edition requires that
1138
+ # chests for example must be present and in range to open its inventory.
1139
+ packet_container_open:
1140
+ !id: 0x2e
1141
+ !bound: client
1142
+ # WindowID is the ID representing the window that is being opened. It may be used later to close the
1143
+ # container using a ContainerClose packet.
1144
+ window_id: WindowID
1145
+ # ContainerType is the type ID of the container that is being opened when opening the container at the
1146
+ # position of the packet. It depends on the block/entity, and could, for example, be the window type of
1147
+ # a chest or a hopper, but also a horse inventory.
1148
+ window_type: WindowType
1149
+ # ContainerPosition is the position of the container opened. The position must point to a block entity
1150
+ # that actually has a container. If that is not the case, the window will not be opened and the packet
1151
+ # will be ignored, if a valid ContainerEntityUniqueID has not also been provided.
1152
+ coordinates: BlockCoordinates
1153
+ # ContainerEntityUniqueID is the unique ID of the entity container that was opened. It is only used if
1154
+ # the ContainerType is one that points to an entity, for example a horse.
1155
+ runtime_entity_id: zigzag64
1156
+
1157
+ # ContainerClose is sent by the server to close a container the player currently has opened, which was opened
1158
+ # using the ContainerOpen packet, or by the client to tell the server it closed a particular container, such
1159
+ # as the crafting grid.
1160
+ packet_container_close:
1161
+ !id: 0x2f
1162
+ !bound: both
1163
+ # WindowID is the ID representing the window of the container that should be closed. It must be equal to
1164
+ # the one sent in the ContainerOpen packet to close the designated window.
1165
+ window_id: WindowID
1166
+ # ServerSide determines whether or not the container was force-closed by the server. If this value is
1167
+ # not set correctly, the client may ignore the packet and respond with a PacketViolationWarning.
1168
+ server: bool
1169
+
1170
+ # PlayerHotBar is sent by the server to the client. It used to be used to link hot bar slots of the player to
1171
+ # actual slots in the inventory, but as of 1.2, this was changed and hot bar slots are no longer a free
1172
+ # floating part of the inventory.
1173
+ # Since 1.2, the packet has been re-purposed, but its new functionality is not clear.
1174
+ packet_player_hotbar:
1175
+ !id: 0x30
1176
+ !bound: both
1177
+ selected_slot: varint
1178
+ window_id: WindowID
1179
+ select_slot: bool
1180
+
1181
+ # InventoryContent is sent by the server to update the full content of a particular inventory. It is usually
1182
+ # sent for the main inventory of the player, but also works for other inventories that are currently opened
1183
+ # by the player.
1184
+ packet_inventory_content:
1185
+ !id: 0x31
1186
+ !bound: both
1187
+ # WindowID is the ID that identifies one of the windows that the client currently has opened, or one of
1188
+ # the consistent windows such as the main inventory.
1189
+ window_id: WindowIDVarint
1190
+ # Content is the new content of the inventory. The length of this slice must be equal to the full size of
1191
+ # the inventory window updated.
1192
+ input: ItemStacks
1193
+
1194
+ # InventorySlot is sent by the server to update a single slot in one of the inventory windows that the client
1195
+ # currently has opened. Usually this is the main inventory, but it may also be the off hand or, for example,
1196
+ # a chest inventory.
1197
+ packet_inventory_slot:
1198
+ !id: 0x32
1199
+ !bound: both
1200
+ # WindowID is the ID of the window that the packet modifies. It must point to one of the windows that the
1201
+ # client currently has opened.
1202
+ window_id: WindowIDVarint
1203
+ # Slot is the index of the slot that the packet modifies. The new item will be set to the slot at this
1204
+ # index.
1205
+ slot: varint
1206
+ # NewItem is the item to be put in the slot at Slot. It will overwrite any item that may currently
1207
+ # be present in that slot.
1208
+ item: Item
1209
+
1210
+ # ContainerSetData is sent by the server to update specific data of a single container, meaning a block such
1211
+ # as a furnace or a brewing stand. This data is usually used by the client to display certain features
1212
+ # client-side.
1213
+ packet_container_set_data:
1214
+ !id: 0x33
1215
+ !bound: client
1216
+ # WindowID is the ID of the window that should have its data set. The player must have a window open with
1217
+ # the window ID passed, or nothing will happen.
1218
+ window_id: WindowID
1219
+ # Key is the key of the property. It is one of the constants that can be found above. Multiple properties
1220
+ # share the same key, but the functionality depends on the type of the container that the data is set to.
1221
+ # IF FURNACE:
1222
+ # 0: furnace_tick_count
1223
+ # 1: furnace_lit_time
1224
+ # 2: furnace_lit_duration
1225
+ # 3: furnace_stored_xp
1226
+ # 4: furnace_fuel_aux
1227
+ # IF BREWING STAND:
1228
+ # 0: brew_time
1229
+ # 1: brew_fuel_amount
1230
+ # 2: brew_fuel_total
1231
+ property: zigzag32
1232
+ # Value is the value of the property. Its use differs per property.
1233
+ value: zigzag32
1234
+
1235
+ packet_crafting_data:
1236
+ !id: 0x34
1237
+ !bound: client
1238
+ recipes: Recipes
1239
+ # PotionContainerChangeRecipes is a list of all recipes to convert a potion from one type to another,
1240
+ # such as from a drinkable potion to a splash potion, or from a splash potion to a lingering potion.
1241
+ potion_type_recipes: PotionTypeRecipes
1242
+ potion_container_recipes: PotionContainerChangeRecipes
1243
+ # MaterialReducers is a list of all material reducers which is used in education edition chemistry.
1244
+ material_reducers: MaterialReducer[]varint
1245
+ # ClearRecipes indicates if all recipes currently active on the client should be cleaned. Doing this
1246
+ # means that the client will have no recipes active by itself: Any CraftingData packets previously sent
1247
+ # will also be discarded, and only the recipes in this CraftingData packet will be used.
1248
+ clear_recipes: bool
1249
+
1250
+ # CraftingEvent is sent by the client when it crafts a particular item. Note that this packet may be fully
1251
+ # ignored, as the InventoryTransaction packet provides all the information required.
1252
+ packet_crafting_event:
1253
+ !id: 0x35
1254
+ !bound: both
1255
+ # WindowID is the ID representing the window that the player crafted in.
1256
+ window_id: WindowID
1257
+ # CraftingType is a type that indicates the way the crafting was done, for example if a crafting table
1258
+ # was used.
1259
+ recipe_type: zigzag32 =>
1260
+ 0: inventory
1261
+ 1: crafting
1262
+ 2: workbench
1263
+ # RecipeUUID is the UUID of the recipe that was crafted. It points to the UUID of the recipe that was
1264
+ # sent earlier in the CraftingData packet.
1265
+ recipe_id: uuid
1266
+ # Input is a list of items that the player put into the recipe so that it could create the Output items.
1267
+ # These items are consumed in the process.
1268
+ input: Item[]varint
1269
+ # Output is a list of items that were obtained as a result of crafting the recipe.
1270
+ result: Item[]varint
1271
+
1272
+ # GUIDataPickItem is sent by the server to make the client 'select' a hot bar slot. It currently appears to
1273
+ # be broken however, and does not actually set the selected slot to the hot bar slot set in the packet.
1274
+ packet_gui_data_pick_item:
1275
+ !id: 0x36
1276
+ !bound: client
1277
+ # ItemName is the name of the item that shows up in the top part of the popup that shows up when
1278
+ # selecting an item. It is shown as if an item was selected by the player itself.
1279
+ item_name: string
1280
+ # ItemEffects is the line under the ItemName, where the effects of the item are usually situated.
1281
+ item_effects: string
1282
+ # HotBarSlot is the hot bar slot to be selected/picked. This does not currently work, so it does not
1283
+ # matter what number this is.
1284
+ hotbar_slot: li32
1285
+
1286
+ # AdventureSettings is sent by the server to update game-play related features, in particular permissions to
1287
+ # access these features for the client. It includes allowing the player to fly, build and mine, and attack
1288
+ # entities. Most of these flags should be checked server-side instead of using this packet only.
1289
+ # The client may also send this packet to the server when it updates one of these settings through the
1290
+ # in-game settings interface. The server should verify if the player actually has permission to update those
1291
+ # settings.
1292
+ packet_adventure_settings:
1293
+ !id: 0x37
1294
+ !bound: both
1295
+ # Flags is a set of flags that specify certain properties of the player, such as whether or not it can
1296
+ # fly and/or move through blocks. It is one of the AdventureFlag constants above.
1297
+ flags: AdventureFlags
1298
+ # CommandPermissionLevel is a permission level that specifies the kind of commands that the player is
1299
+ # allowed to use.
1300
+ command_permission: CommandPermissionLevelVarint
1301
+ # ActionPermissions is, much like Flags, a set of flags that specify actions that the player is allowed
1302
+ # to undertake, such as whether it is allowed to edit blocks, open doors etc. It is a combination of the
1303
+ # ActionPermission constants above.
1304
+ action_permissions: ActionPermissions
1305
+ # PermissionLevel is the permission level of the player as it shows up in the player list built up using
1306
+ # the PlayerList packet. It is one of the PermissionLevel constants above.
1307
+ permission_level: PermissionLevel
1308
+ # Custom permissions
1309
+ custom_stored_permissions: varint
1310
+ # PlayerUniqueID is a unique identifier of the player. It appears it is not required to fill this field
1311
+ # out with a correct value. Simply writing 0 seems to work.
1312
+ user_id: li64
1313
+
1314
+ AdventureFlags: [ "bitflags",
1315
+ {
1316
+ "type": "varint",
1317
+ "flags": {
1318
+ "world_immutable": 1,
1319
+ "no_pvp": 2,
1320
+ "auto_jump": 0x20,
1321
+ "allow_flight": 0x40,
1322
+ "no_clip": 0x80,
1323
+ "world_builder": 0x100,
1324
+ "flying": 0x200,
1325
+ "muted": 0x400
1326
+ }
1327
+ }
1328
+ ]
1329
+
1330
+ ActionPermissions: [ "bitflags",
1331
+ {
1332
+ "type": "varint",
1333
+ "flags": {
1334
+ "mine": 0x10001,
1335
+ "doors_and_switches": 0x10002,
1336
+ "open_containers": 0x10004,
1337
+ "attack_players": 0x10008,
1338
+ "attack_mobs": 0x10010,
1339
+ "operator": 0x10020,
1340
+ "teleport": 0x10080,
1341
+ "build": 0x10100,
1342
+ "default": 0x10200
1343
+ }
1344
+ }
1345
+ ]
1346
+
1347
+ packet_block_entity_data:
1348
+ !id: 0x38
1349
+ !bound: both
1350
+ position: BlockCoordinates
1351
+ nbt: nbt
1352
+
1353
+ packet_player_input:
1354
+ !id: 0x39
1355
+ !bound: server
1356
+ motion_x: lf32
1357
+ motion_z: lf32
1358
+ jumping: bool
1359
+ sneaking: bool
1360
+
1361
+ # LevelChunk is sent by the server to provide the client with a chunk of a world data (16xYx16 blocks).
1362
+ # Typically a certain amount of chunks is sent to the client before sending it the spawn PlayStatus packet,
1363
+ # so that the client spawns in a loaded world.
1364
+ packet_level_chunk:
1365
+ !id: 0x3a
1366
+ !bound: client
1367
+ # ChunkX is the X coordinate of the chunk sent. (To translate a block's X to a chunk's X: x >> 4)
1368
+ x: zigzag32
1369
+ # ChunkZ is the Z coordinate of the chunk sent. (To translate a block's Z to a chunk's Z: z >> 4)
1370
+ z: zigzag32
1371
+ # SubChunkCount is the amount of sub chunks that are part of the chunk sent. Depending on if the cache
1372
+ # is enabled, a list of blob hashes will be sent, or, if disabled, the sub chunk data.
1373
+ # On newer versions, if this is a negative value it indicates to use the Subchunk Polling mechanism
1374
+ sub_chunk_count: varint
1375
+ # HighestSubChunk is the highest sub-chunk at the position that is not all air. It is only set if the
1376
+ # RequestMode is set to protocol.SubChunkRequestModeLimited.
1377
+ highest_subchunk_count: sub_chunk_count ?
1378
+ if -2: lu16
1379
+ # CacheEnabled specifies if the client blob cache should be enabled. This system is based on hashes of
1380
+ # blobs which are consistent and saved by the client in combination with that blob, so that the server
1381
+ # does not have to send the same chunk multiple times. If the client does not yet have a blob with the hash sent,
1382
+ # it will send a ClientCacheBlobStatus packet containing the hashes is does not have the data of.
1383
+ cache_enabled: bool
1384
+ blobs: cache_enabled?
1385
+ if true:
1386
+ # BlobHashes is a list of all blob hashes used in the chunk. It is composed of SubChunkCount + 1 hashes,
1387
+ # with the first SubChunkCount hashes being those of the sub chunks and the last one that of the biome
1388
+ # of the chunk.
1389
+ # If CacheEnabled is set to false, BlobHashes can be left empty.
1390
+ hashes: lu64[]varint
1391
+ # RawPayload is a serialised string of chunk data. The data held depends on if CacheEnabled is set to
1392
+ # true. If set to false, the payload is composed of multiple sub-chunks, each of which carry a version
1393
+ # which indicates the way they are serialised, followed by biomes, border blocks and tile entities. If
1394
+ # CacheEnabled is true, the payload consists out of the border blocks and tile entities only.
1395
+ payload: ByteArray
1396
+
1397
+ packet_set_commands_enabled:
1398
+ !id: 0x3b
1399
+ !bound: client
1400
+ enabled: bool
1401
+
1402
+ packet_set_difficulty:
1403
+ !id: 0x3c
1404
+ !bound: client
1405
+ difficulty: varint
1406
+
1407
+ packet_change_dimension:
1408
+ !id: 0x3d
1409
+ !bound: client
1410
+ dimension: zigzag32
1411
+ position: vec3f
1412
+ respawn: bool
1413
+
1414
+ # SetPlayerGameType is sent by the server to update the game type (game mode) of the player
1415
+ packet_set_player_game_type:
1416
+ !id: 0x3e
1417
+ !bound: both
1418
+ # The new gamemode for the player.
1419
+ # Some of these game types require additional flags to be set in an AdventureSettings packet for
1420
+ # the game mode to obtain its full functionality.
1421
+ gamemode: GameMode
1422
+
1423
+ packet_player_list:
1424
+ !id: 0x3f
1425
+ !bound: client
1426
+ records: PlayerRecords
1427
+
1428
+ packet_simple_event:
1429
+ !id: 0x40
1430
+ !bound: client
1431
+ event_type: lu16
1432
+
1433
+ # Event is sent by the server to send an event with additional data. It is typically sent to the client for
1434
+ # telemetry reasons, much like the SimpleEvent packet.
1435
+ packet_event:
1436
+ !id: 0x41
1437
+ !bound: client
1438
+ runtime_id: varint64
1439
+ event_type: zigzag32 =>
1440
+ 0: achievement_awarded
1441
+ 1: entity_interact
1442
+ 2: portal_built
1443
+ 3: portal_used
1444
+ 4: mob_killed
1445
+ 5: cauldron_used
1446
+ 6: player_death
1447
+ 7: boss_killed
1448
+ 8: agent_command
1449
+ 9: agent_created
1450
+ 10: banner_pattern_removed
1451
+ 11: commaned_executed
1452
+ 12: fish_bucketed
1453
+ 13: mob_born
1454
+ 14: pet_died
1455
+ 15: cauldron_block_used
1456
+ 16: composter_block_used
1457
+ 17: bell_block_used
1458
+ 18: actor_definition
1459
+ 19: raid_update
1460
+ 20: player_movement_anomaly
1461
+ 21: player_moement_corrected
1462
+ 22: honey_harvested
1463
+ 23: target_block_hit
1464
+ 24: piglin_barter
1465
+ 25: waxed_or_unwaxed_copper
1466
+ use_player_id: u8
1467
+ event_data: restBuffer # Unknown data, TODO: add
1468
+
1469
+ packet_spawn_experience_orb:
1470
+ !id: 0x42
1471
+ !bound: client
1472
+ position: vec3f
1473
+ count: zigzag32
1474
+
1475
+ UpdateMapFlags: [ "bitflags", {
1476
+ "type": "varint",
1477
+ "flags": [
1478
+ "void",
1479
+ "texture",
1480
+ "decoration",
1481
+ "initialisation"
1482
+ ]
1483
+ }]
1484
+
1485
+ # ClientBoundMapItemData is sent by the server to the client to update the data of a map shown to the client.
1486
+ # It is sent with a combination of flags that specify what data is updated.
1487
+ # The ClientBoundMapItemData packet may be used to update specific parts of the map only. It is not required
1488
+ # to send the entire map each time when updating one part.
1489
+ packet_clientbound_map_item_data:
1490
+ !id: 0x43
1491
+ !bound: client
1492
+ # MapID is the unique identifier that represents the map that is updated over network. It remains
1493
+ # consistent across sessions.
1494
+ map_id: zigzag64
1495
+ # UpdateFlags is a combination of flags found above that indicate what parts of the map should be updated
1496
+ # client-side.
1497
+ update_flags: UpdateMapFlags
1498
+ # Dimension is the dimension of the map that should be updated, for example the overworld (0), the nether
1499
+ # (1) or the end (2).
1500
+ dimension: u8
1501
+ # LockedMap specifies if the map that was updated was a locked map, which may be done using a cartography
1502
+ # table.
1503
+ locked: bool
1504
+ # Origin is the center position of the map being updated.
1505
+ origin: BlockCoordinates
1506
+ # The following fields apply only for the MapUpdateFlagInitialisation.
1507
+ # MapsIncludedIn holds an array of map IDs that the map updated is included in. This has to do with the
1508
+ # scale of the map: Each map holds its own map ID and all map IDs of maps that include this map and have
1509
+ # a bigger scale. This means that a scale 0 map will have 5 map IDs in this slice, whereas a scale 4 map
1510
+ # will have only 1 (its own).
1511
+ # The actual use of this field remains unknown.
1512
+ included_in: update_flags.initialisation ?
1513
+ if true: zigzag64[]varint
1514
+ # Scale is the scale of the map as it is shown in-game. It is written when any of the MapUpdateFlags are
1515
+ # set to the UpdateFlags field.
1516
+ scale: update_flags.initialisation || update_flags.decoration || update_flags.texture ?
1517
+ if true: u8
1518
+ # The following fields apply only for the MapUpdateFlagDecoration.
1519
+ # TrackedObjects is a list of tracked objects on the map, which may either be entities or blocks. The
1520
+ # client makes sure these tracked objects are actually tracked. (position updated etc.)
1521
+ tracked: update_flags.decoration ?
1522
+ if true:
1523
+ objects: TrackedObject[]varint
1524
+ decorations: MapDecoration[]varint
1525
+ # Updates to the map contents itself (texture)
1526
+ texture: update_flags.texture ?
1527
+ if true:
1528
+ # Width is the width of the texture area that was updated. The width may be a subset of the total width
1529
+ # of the map.
1530
+ width: zigzag32
1531
+ # Height is the height of the texture area that was updated. The height may be a subset of the total
1532
+ # height of the map
1533
+ height: zigzag32
1534
+ # XOffset is the X offset in pixels at which the updated texture area starts. From this X, the updated
1535
+ # texture will extend exactly Width pixels to the right.
1536
+ x_offset: zigzag32
1537
+ # YOffset is the Y offset in pixels at which the updated texture area starts. From this Y, the updated
1538
+ # texture will extend exactly Height pixels up.
1539
+ y_offset: zigzag32
1540
+ # Pixels is a list of pixel colours for the new texture of the map. It is indexed as Pixels[y][x], with
1541
+ # the length of the outer slice having to be exactly Height long and the inner slices exactly Width long.
1542
+ # To access this array, use $width * y + x
1543
+ pixels: varint[]varint
1544
+
1545
+
1546
+ packet_map_info_request:
1547
+ !id: 0x44
1548
+ !bound: both
1549
+ map_id: zigzag64
1550
+ # ClientPixels is a map of pixels sent from the client to notify the server about the pixels that it isn't
1551
+ # aware of.
1552
+ client_pixels: []lu32
1553
+ rgba: li32
1554
+ index: lu16
1555
+
1556
+ # RequestChunkRadius is sent by the client to the server to update the server on the chunk view radius that
1557
+ # it has set in the settings. The server may respond with a ChunkRadiusUpdated packet with either the chunk
1558
+ # radius requested, or a different chunk radius if the server chooses so.
1559
+ packet_request_chunk_radius:
1560
+ !id: 0x45
1561
+ !bound: both
1562
+ # ChunkRadius is the requested chunk radius. This value is always the value set in the settings of the
1563
+ # player.
1564
+ chunk_radius: zigzag32
1565
+
1566
+ # ChunkRadiusUpdated is sent by the server in response to a RequestChunkRadius packet. It defines the chunk
1567
+ # radius that the server allows the client to have. This may be lower than the chunk radius requested by the
1568
+ # client in the RequestChunkRadius packet.
1569
+ packet_chunk_radius_update:
1570
+ !id: 0x46
1571
+ !bound: client
1572
+ # ChunkRadius is the final chunk radius that the client will adapt when it receives the packet. It does
1573
+ # not have to be the same as the requested chunk radius.
1574
+ chunk_radius: zigzag32
1575
+
1576
+ packet_item_frame_drop_item:
1577
+ !id: 0x47
1578
+ !bound: both
1579
+ coordinates: BlockCoordinates
1580
+
1581
+ packet_game_rules_changed:
1582
+ !id: 0x48
1583
+ !bound: client
1584
+ rules: GameRules
1585
+
1586
+ # Camera is sent by the server to use an Education Edition camera on a player. It produces an image
1587
+ # client-side.
1588
+ packet_camera:
1589
+ !id: 0x49
1590
+ !bound: client
1591
+ # CameraEntityUniqueID is the unique ID of the camera entity from which the picture was taken.
1592
+ camera_entity_unique_id: zigzag64
1593
+ # TargetPlayerUniqueID is the unique ID of the target player. The unique ID is a value that remains
1594
+ # consistent across different sessions of the same world, but most servers simply fill the runtime ID of
1595
+ # the player out for this field.
1596
+ target_player_unique_id: zigzag64
1597
+
1598
+ packet_boss_event:
1599
+ !id: 0x4a
1600
+ !bound: both
1601
+ boss_entity_id: zigzag64
1602
+ type: varint =>
1603
+ # S2C: Shows the boss-bar to the player.
1604
+ 0: show_bar
1605
+ # C2S: Registers a player to a boss fight.
1606
+ 1: register_player
1607
+ # S2C: Removes the boss-bar from the client.
1608
+ 2: hide_bar
1609
+ # C2S: Unregisters a player from a boss fight.
1610
+ 3: unregister_player
1611
+ # S2C: Sets the bar percentage.
1612
+ 4: set_bar_progress
1613
+ # S2C: Sets title of the bar.
1614
+ 5: set_bar_title
1615
+ # S2C: darkens the sky
1616
+ 6: update_properties
1617
+ # S2C: Not implemented :( Intended to alter bar appearance, but these currently produce no effect on client-side whatsoever.
1618
+ 7: texture
1619
+ # C2S: Client asking the server to resend all boss data.
1620
+ 8: query
1621
+ _: type?
1622
+ if show_bar:
1623
+ # BossBarTitle is the title shown above the boss bar. It currently does not function, and instead uses
1624
+ # the name tag of the boss entity at all times. It is only set if the EventType is BossEventShow or
1625
+ # BossEventTitle.
1626
+ title: string
1627
+ # HealthPercentage is the percentage of health that is shown in the boss bar. It currently does not
1628
+ # function, and instead uses the health percentage of the boss entity at all times. It is only set if the
1629
+ # EventType is BossEventShow or BossEventHealthPercentage.
1630
+ progress: lf32
1631
+ # ScreenDarkening currently seems not to do anything.
1632
+ screen_darkening: li16
1633
+ # Colour is the colour of the boss bar that is shown when a player is subscribed. It currently does not
1634
+ # function. It is only set if the EventType is BossEventShow, BossEventAppearanceProperties or
1635
+ # BossEventTexture.
1636
+ # Format is ARGB
1637
+ color: varint
1638
+ # Overlay is the overlay of the boss bar that is shown on top of the boss bar when a player is
1639
+ # subscribed. It currently does not function. It is only set if the EventType is BossEventShow,
1640
+ # BossEventAppearanceProperties or BossEventTexture.
1641
+ overlay: varint
1642
+ if register_player or unregister_player or query:
1643
+ # PlayerUniqueID is the unique ID of the player that is registered to or unregistered from the boss
1644
+ # fight. It is set if EventType is either BossEventRegisterPlayer or BossEventUnregisterPlayer.
1645
+ player_id: zigzag64
1646
+ if set_bar_progress:
1647
+ progress: lf32
1648
+ if set_bar_title:
1649
+ title: string
1650
+ if update_properties:
1651
+ screen_darkening: li16
1652
+ color: varint
1653
+ overlay: varint
1654
+ if texture:
1655
+ color: varint
1656
+ overlay: varint
1657
+
1658
+ packet_show_credits:
1659
+ !id: 0x4b
1660
+ !bound: client
1661
+ runtime_entity_id: varint64
1662
+ status: zigzag32
1663
+
1664
+ # This packet sends a list of commands to the client. Commands can have
1665
+ # arguments, and some of those arguments can have 'enum' values, which are a list of possible
1666
+ # values for the argument. The serialization is rather complex and involves palettes like chunks.
1667
+ ## In bedrock-protocol, listen to on('client.commands') for a simpler representation
1668
+ packet_available_commands:
1669
+ !id: 0x4c
1670
+ !bound: client
1671
+ # The length of the enums for all the command parameters in this packet
1672
+ values_len: varint
1673
+ # Not read from stream: instead calculated from the `values_len` field
1674
+ #
1675
+ # If the values_len < 0xff => byte,
1676
+ # If the values_len < 0xffff => short,
1677
+ # If the values_len < 0xffffff => int
1678
+ _enum_type: '["enum_size_based_on_values_len"]'
1679
+ # Here all the enum values for all of the possible commands are stored to one array palette
1680
+ enum_values: string[]$values_len
1681
+ # Integer parameters may sometimes have a prefix, such as the XP command:
1682
+ # /xp <amount: int> [player: target] <- here, the xp command gives experience points
1683
+ # /xp <amount: int>L [player: target] <- here, the xp command gives experience levels
1684
+ # This is the palette of suffixes
1685
+ suffixes: string[]varint
1686
+ # The list of enum objects
1687
+ enums: []varint
1688
+ # The name of the enum
1689
+ name: string
1690
+ # The values in the enum
1691
+ values: []varint
1692
+ # The indexes to value in the palette
1693
+ _: ../_enum_type?
1694
+ if byte: u8
1695
+ if short: lu16
1696
+ if int: lu32
1697
+ command_data: []varint
1698
+ name: string
1699
+ description: string
1700
+ flags: lu16
1701
+ permission_level: u8
1702
+ alias: li32
1703
+ # The list of overload parameters for this command
1704
+ overloads: []varint
1705
+ # Each of the parameters gets an array of posible overloads
1706
+ _: []varint
1707
+ # The name of the parameter shown to the user (the `amount` in `/xp <amount: int>`)
1708
+ parameter_name: string
1709
+ value_type: lu16 =>
1710
+ 1: int
1711
+ 3: float
1712
+ 4: value
1713
+ 5: wildcard_int
1714
+ 6: operator
1715
+ 7: command_operator
1716
+ 8: target
1717
+ 10: wildcard_target
1718
+ 17: file_path
1719
+ 23: integer_range
1720
+ 38: equipment_slots
1721
+ 39: string
1722
+ 47: block_position
1723
+ 48: position
1724
+ 51: message
1725
+ 53: raw_text
1726
+ 57: json
1727
+ 67: block_states
1728
+ 70: command
1729
+ # In MC, this + prior field are combined to one 32bit bitfield
1730
+ enum_type: lu16 =>
1731
+ 0x10: valid
1732
+ 0x20: enum
1733
+ 0x100: suffixed
1734
+ 0x400: soft_enum
1735
+ # Is this parameter required?
1736
+ optional: bool
1737
+ # Additinal options for this command (thanks macroshaft...)
1738
+ options: CommandFlags
1739
+ # There are two types of enums: static enums which cannot be changed after sending AvaliableCommands,
1740
+ # (unless you resend the whole packet) and 'soft' or 'dynamic' enums like below which is an array
1741
+ # that can be updated with the UpdateSoftEnum packet
1742
+ dynamic_enums: []varint
1743
+ name: string
1744
+ values: string[]varint
1745
+ enum_constraints: []varint
1746
+ value_index: li32
1747
+ enum_index: li32
1748
+ constraints: []varint
1749
+ constraint: u8 =>
1750
+ 0: cheats_enabled
1751
+ 1: operator_permissions
1752
+ 2: host_permissions
1753
+
1754
+ # ParamOptionCollapseEnum specifies if the enum (only if the Type is actually an enum type. If not,
1755
+ # setting this to true has no effect) should be collapsed. This means that the options of the enum are
1756
+ # never shown in the actual usage of the command, but only as auto-completion, like it automatically does
1757
+ # with enums that have a big amount of options. To illustrate, it can make
1758
+ # <false|true|yes|no> <$Name: bool>.
1759
+ CommandFlags: [ "bitfield", [
1760
+ { "name": "unused", "size": 1, "signed": false },
1761
+ { "name": "collapse_enum", "size": 1, "signed": false },
1762
+ { "name": "has_semantic_constraint", "size": 1, "signed": false },
1763
+ { "name": "as_chained_command", "size": 1, "signed": false },
1764
+ { "name": "unknown2", "size": 4, "signed": false }, # 4 unused upper bits
1765
+ ]]
1766
+
1767
+ # enum_size_based_on_values_len: native
1768
+
1769
+ # CommandRequest is sent by the client to request the execution of a server-side command. Although some
1770
+ # servers support sending commands using the Text packet, this packet is guaranteed to have the correct
1771
+ # result.
1772
+ packet_command_request:
1773
+ !id: 0x4d
1774
+ !bound: server
1775
+ # CommandLine is the raw entered command line. The client does no parsing of the command line by itself
1776
+ # (unlike it did in the early stages), but lets the server do that.
1777
+ command: string
1778
+ # Origin holds information about the command sender that will be returnd back in the command response
1779
+ origin: CommandOrigin
1780
+ # Internal specifies if the command request internal. Setting it to false seems to work and the usage of
1781
+ # this field is not known.
1782
+ internal: bool
1783
+ # Version is the version of the command that is being executed. This field currently has no purpose or functionality.
1784
+ version: varint
1785
+
1786
+
1787
+ # CommandBlockUpdate is sent by the client to update a command block at a specific position. The command
1788
+ # block may be either a physical block or an entity.
1789
+ packet_command_block_update:
1790
+ !id: 0x4e
1791
+ !bound: server
1792
+ # Block specifies if the command block updated was an actual physical block. If false, the command block
1793
+ # is in a minecart and has an entity runtime ID instead.
1794
+ is_block: bool
1795
+ # Position is the position of the command block updated. It is only set if Block is set to true. Nothing
1796
+ # happens if no command block is set at this position.
1797
+ _: is_block ?
1798
+ if true:
1799
+ # Position is the position of the command block updated. It is only set if Block is set to true. Nothing
1800
+ # happens if no command block is set at this position.
1801
+ position: BlockCoordinates
1802
+ # Mode is the mode of the command block. It is either CommandBlockImpulse, CommandBlockChain or
1803
+ # CommandBlockRepeat. It is only set if Block is set to true.
1804
+ mode: varint =>
1805
+ 0: impulse
1806
+ 1: repeat
1807
+ 2: chain
1808
+ # NeedsRedstone specifies if the command block needs to be powered by redstone to be activated. If false,
1809
+ # the command block is always active. The field is only set if Block is set to true.
1810
+ needs_redstone: bool
1811
+ # Conditional specifies the behaviour of the command block if the command block before it (the opposite
1812
+ # side of the direction the arrow if facing) fails to execute. If set to false, it will activate at all
1813
+ # times, whereas if set to true, it will activate only if the previous command block executed
1814
+ # successfully. The field is only set if Block is set to true.
1815
+ conditional: bool
1816
+ if false:
1817
+ minecart_entity_runtime_id: varint64
1818
+ # Command is the command currently entered in the command block. This is the command that is executed
1819
+ # when the command block is activated.
1820
+ command: string
1821
+ # LastOutput is the output of the last command executed by the command block. It may be left empty to
1822
+ # show simply no output at all, in combination with setting ShouldTrackOutput to false.
1823
+ last_output: string
1824
+ # Name is the name of the command block updated. If not empty, it will show this name hovering above the
1825
+ # command block when hovering over the block with the cursor.
1826
+ name: string
1827
+ # ShouldTrackOutput specifies if the command block tracks output. If set to false, the output box won't
1828
+ # be shown within the command block.
1829
+ should_track_output: bool
1830
+ # TickDelay is the delay in ticks between executions of a command block, if it is a repeating command
1831
+ # block.
1832
+ tick_delay: li32
1833
+ # ExecuteOnFirstTick specifies if the command block should execute on the first tick, AKA as soon as the
1834
+ # command block is enabled.
1835
+ execute_on_first_tick: bool
1836
+
1837
+ packet_command_output:
1838
+ !id: 0x4f
1839
+ !bound: client
1840
+ # CommandOrigin is the data specifying the origin of the command. In other words, the source that the
1841
+ # command request was from, such as the player itself or a websocket server. The client forwards the
1842
+ # messages in this packet to the right origin, depending on what is sent here.
1843
+ origin: CommandOrigin
1844
+ # OutputType specifies the type of output that is sent.
1845
+ output_type: i8 =>
1846
+ 1: last
1847
+ 2: silent
1848
+ 3: all
1849
+ 4: data_set
1850
+ # SuccessCount is the amount of times that a command was executed successfully as a result of the command
1851
+ # that was requested. For servers, this is usually a rather meaningless fields, but for vanilla, this is
1852
+ # applicable for commands created with Functions.
1853
+ success_count: varint
1854
+ # OutputMessages is a list of all output messages that should be sent to the player. Whether they are
1855
+ # shown or not, depends on the type of the messages.
1856
+ output: []varint
1857
+ # Success indicates if the output message was one of a successful command execution. If set to true, the
1858
+ # output message is by default coloured white, whereas if set to false, the message is by default
1859
+ # coloured red.
1860
+ success: bool
1861
+ # Message is the message that is sent to the client in the chat window. It may either be simply a
1862
+ # message or a translated built-in string like 'commands.tp.success.coordinates', combined with specific
1863
+ # parameters below.
1864
+ message_id: string
1865
+ # Parameters is a list of parameters that serve to supply the message sent with additional information,
1866
+ # such as the position that a player was teleported to or the effect that was applied to an entity.
1867
+ # These parameters only apply for the Minecraft built-in command output.
1868
+ parameters: string[]varint
1869
+ data_set: output_type ?
1870
+ if data_set: string
1871
+ default: void
1872
+
1873
+
1874
+ # UpdateTrade is sent by the server to update the trades offered by a villager to a player. It is sent at the
1875
+ # moment that a player interacts with a villager.
1876
+ packet_update_trade:
1877
+ !id: 0x50
1878
+ !bound: client
1879
+ # WindowID is the ID that identifies the trading window that the client currently has opened.
1880
+ window_id: WindowID
1881
+ # WindowType is an identifier specifying the type of the window opened. In vanilla, it appears this is
1882
+ # always filled out with 15.
1883
+ window_type: WindowType
1884
+ # Size is the amount of trading options that the villager has.
1885
+ size: varint
1886
+ # TradeTier is the tier of the villager that the player is trading with. The tier starts at 0 with a
1887
+ # first two offers being available, after which two additional offers are unlocked each time the tier
1888
+ # becomes one higher.
1889
+ trade_tier: varint
1890
+ # VillagerUniqueID is the unique ID of the villager entity that the player is trading with. The
1891
+ # TradeTier sent above applies to this villager.
1892
+ villager_unique_id: varint64
1893
+ # EntityUniqueID is the unique ID of the entity (usually a player) for which the trades are updated. The
1894
+ # updated trades may apply only to this entity.
1895
+ entity_unique_id: varint64
1896
+ # DisplayName is the name displayed at the top of the trading UI. It is usually used to represent the
1897
+ # profession of the villager in the UI.
1898
+ display_name: string
1899
+ # NewTradeUI specifies if the villager should be using the new trade UI (The one added in 1.11.) rather
1900
+ # than the old one. This should usually be set to true.
1901
+ new_trading_ui: bool
1902
+ # Trading based on Minecraft economy - specifies if the prices of the villager's offers are modified by an increase in
1903
+ # demand for the item. (A mechanic added in 1.11.) Buying more of the same item will increase the price
1904
+ # of that particular item.
1905
+ # https://minecraft.gamepedia.com/Trading#Economics
1906
+ economic_trades: bool
1907
+ # NBT serialised compound of offers that the villager has.
1908
+ offers: nbt
1909
+
1910
+ # UpdateEquip is sent by the server to the client upon opening a horse inventory. It is used to set the
1911
+ # content of the inventory and specify additional properties, such as the items that are allowed to be put
1912
+ # in slots of the inventory.
1913
+ packet_update_equipment:
1914
+ !id: 0x51
1915
+ !bound: client
1916
+ # WindowID is the identifier associated with the window that the UpdateEquip packet concerns. It is the
1917
+ # ID sent for the horse inventory that was opened before this packet was sent.
1918
+ window_id: WindowID
1919
+ # WindowType is the type of the window that was opened. Generally, this is the type of a horse inventory,
1920
+ # as the packet is specifically made for that.
1921
+ window_type: WindowType
1922
+ # Size is the size of the horse inventory that should be opened. A bigger size does, in fact, change the
1923
+ # amount of slots displayed.
1924
+ size: u8
1925
+ # EntityUniqueID is the unique ID of the entity whose equipment was 'updated' to the player. It is
1926
+ # typically the horse entity that had its inventory opened.
1927
+ entity_id: zigzag64
1928
+ # `inventory` is a network NBT serialised compound holding the content of the inventory of
1929
+ # the entity (the equipment) and additional data such as the allowed items for a particular slot, used to
1930
+ # make sure only saddles can be put in the saddle slot etc.
1931
+ inventory: nbt
1932
+
1933
+
1934
+ # ResourcePackDataInfo is sent by the server to the client to inform the client about the data contained in
1935
+ # one of the resource packs that are about to be sent.
1936
+ packet_resource_pack_data_info:
1937
+ !id: 0x52
1938
+ !bound: client
1939
+ # UUID is the unique ID of the resource pack that the info concerns.
1940
+ pack_id: string
1941
+ # DataChunkSize is the maximum size in bytes of the chunks in which the total size of the resource pack
1942
+ # to be sent will be divided. A size of 1MB (1024*1024) means that a resource pack of 15.5MB will be
1943
+ # split into 16 data chunks.
1944
+ max_chunk_size: lu32
1945
+ # ChunkCount is the total amount of data chunks that the sent resource pack will exist out of. It is the
1946
+ # total size of the resource pack divided by the DataChunkSize field.
1947
+ # The client doesn't actually seem to use this field. Rather, it divides the size by the chunk size to
1948
+ # calculate it itself.
1949
+ chunk_count: lu32
1950
+ # Size is the total size in bytes that the resource pack occupies. This is the size of the compressed
1951
+ # archive (zip) of the resource pack.
1952
+ size: lu64
1953
+ # Hash is a SHA256 hash of the content of the resource pack.
1954
+ hash: ByteArray
1955
+ # Premium specifies if the resource pack was a premium resource pack, meaning it was bought from the
1956
+ # Minecraft store.
1957
+ is_premium: bool
1958
+ # PackType is the type of the resource pack. It is one of the resource pack types listed.
1959
+ pack_type: u8 =>
1960
+ 1: addon
1961
+ 2: cached
1962
+ 3: copy_protected
1963
+ 4: behavior
1964
+ 5: persona_piece
1965
+ 6: resources
1966
+ 7: skins
1967
+ 8: world_template
1968
+
1969
+ # ResourcePackChunkData is sent to the client so that the client can download the resource pack. Each packet
1970
+ # holds a chunk of the compressed resource pack, of which the size is defined in the ResourcePackDataInfo
1971
+ # packet sent before.
1972
+ packet_resource_pack_chunk_data:
1973
+ !id: 0x53
1974
+ !bound: client
1975
+ # UUID is the unique ID of the resource pack that the chunk of data is taken out of.
1976
+ pack_id: string
1977
+ # ChunkIndex is the current chunk index of the chunk. It is a number that starts at 0 and is incremented
1978
+ # for each resource pack data chunk sent to the client.
1979
+ chunk_index: lu32
1980
+ # DataOffset is the current progress in bytes or offset in the data that the resource pack data chunk is
1981
+ # taken from.
1982
+ progress: lu64
1983
+ # RawPayload is a byte slice containing a chunk of data from the resource pack. It must be of the same size or
1984
+ # less than the DataChunkSize set in the ResourcePackDataInfo packet.
1985
+ payload: ByteArray
1986
+
1987
+ # ResourcePackChunkRequest is sent by the client to request a chunk of data from a particular resource pack,
1988
+ # that it has obtained information about in a ResourcePackDataInfo packet.
1989
+ packet_resource_pack_chunk_request:
1990
+ !id: 0x54
1991
+ !bound: server
1992
+ # UUID is the unique ID of the resource pack that the chunk of data is requested from.
1993
+ pack_id: string
1994
+ # ChunkIndex is the requested chunk index of the chunk. It is a number that starts at 0 and is
1995
+ # incremented for each resource pack data chunk requested.
1996
+ chunk_index: lu32
1997
+
1998
+ packet_transfer:
1999
+ !id: 0x55
2000
+ !bound: client
2001
+ server_address: string
2002
+ port: lu16
2003
+
2004
+ packet_play_sound:
2005
+ !id: 0x56
2006
+ !bound: client
2007
+ name: string
2008
+ coordinates: BlockCoordinates
2009
+ volume: lf32
2010
+ pitch: lf32
2011
+
2012
+ packet_stop_sound:
2013
+ !id: 0x57
2014
+ !bound: client
2015
+ name: string
2016
+ stop_all: bool
2017
+
2018
+ # SetTitle is sent by the server to make a title, subtitle or action bar shown to a player. It has several
2019
+ # fields that allow setting the duration of the titles.
2020
+ packet_set_title:
2021
+ !id: 0x58
2022
+ !bound: client
2023
+ # ActionType is the type of the action that should be executed upon the title of a player. It is one of
2024
+ # the constants above and specifies the response of the client to the packet.
2025
+ type: zigzag32 =>
2026
+ 0: clear
2027
+ 1: reset
2028
+ 2: set_title
2029
+ 3: set_subtitle
2030
+ 4: action_bar_message
2031
+ 5: set_durations
2032
+ 6: set_title_json
2033
+ 7: set_subtitle_json
2034
+ 8: action_bar_message_json
2035
+ # Text is the text of the title, which has a different meaning depending on the ActionType that the
2036
+ # packet has. The text is the text of a title, subtitle or action bar, depending on the type set.
2037
+ text: string
2038
+ # FadeInDuration is the duration that the title takes to fade in on the screen of the player. It is
2039
+ # measured in 20ths of a second (AKA in ticks).
2040
+ fade_in_time: zigzag32
2041
+ # RemainDuration is the duration that the title remains on the screen of the player. It is measured in
2042
+ # 20ths of a second (AKA in ticks).
2043
+ stay_time: zigzag32
2044
+ # FadeOutDuration is the duration that the title takes to fade out of the screen of the player. It is
2045
+ # measured in 20ths of a second (AKA in ticks).
2046
+ fade_out_time: zigzag32
2047
+ # XUID is the XBOX Live user ID of the player, which will remain consistent as long as the player is
2048
+ # logged in with the XBOX Live account. It is empty if the user is not logged into its XBL account.
2049
+ xuid: string
2050
+ # PlatformOnlineID is either a uint64 or an empty string.
2051
+ platform_online_id: string
2052
+
2053
+ packet_add_behavior_tree:
2054
+ !id: 0x59
2055
+ !bound: client
2056
+ behaviortree: string
2057
+
2058
+ # StructureBlockUpdate is sent by the client when it updates a structure block using the in-game UI. The
2059
+ # data it contains depends on the type of structure block that it is. In Minecraft Bedrock Edition v1.11,
2060
+ # there is only the Export structure block type, but in v1.13 the ones present in Java Edition will,
2061
+ # according to the wiki, be added too.
2062
+ packet_structure_block_update:
2063
+ !id: 0x5a
2064
+ !bound: client
2065
+ # Position is the position of the structure block that is updated.
2066
+ position: BlockCoordinates
2067
+ # StructureName is the name of the structure that was set in the structure block's UI. This is the name
2068
+ # used to export the structure to a file.
2069
+ structure_name: string
2070
+ # DataField is the name of a function to run, usually used during natural generation. A description can
2071
+ # be found here: https://minecraft.gamepedia.com/Structure_Block#Data.
2072
+ data_field: string
2073
+ # IncludePlayers specifies if the 'Include Players' toggle has been enabled, meaning players are also
2074
+ # exported by the structure block.
2075
+ include_players: bool
2076
+ # ShowBoundingBox specifies if the structure block should have its bounds outlined. A thin line will
2077
+ # encapsulate the bounds of the structure if set to true.
2078
+ show_bounding_box: bool
2079
+ # StructureBlockType is the type of the structure block updated. A list of structure block types that
2080
+ # will be used can be found in the constants above.
2081
+ structure_block_type: zigzag32
2082
+ # Settings is a struct of settings that should be used for exporting the structure. These settings are
2083
+ # identical to the last sent in the StructureBlockUpdate packet by the client.
2084
+ settings: StructureBlockSettings
2085
+ # RedstoneSaveMode is the mode that should be used to save the structure when used with redstone. In
2086
+ # Java Edition, this is always stored in memory, but in Bedrock Edition it can be stored either to disk
2087
+ # or memory. See the constants above for the options.
2088
+ redstone_save_mode: zigzag32
2089
+ # ShouldTrigger specifies if the structure block should be triggered immediately after this packet
2090
+ # reaches the server.
2091
+ should_trigger: bool
2092
+ # Waterlogged specifies if the structure block is waterlogged at the time of the packet being sent.
2093
+ water_logged: bool
2094
+
2095
+ # ShowStoreOffer is sent by the server to show a Marketplace store offer to a player. It opens a window
2096
+ # client-side that displays the item.
2097
+ # The ShowStoreOffer packet only works on the partnered servers: Servers that are not partnered will not have
2098
+ # a store buttons show up in the in-game pause menu and will, as a result, not be able to open store offers
2099
+ # on the client side. Sending the packet does therefore not work when using a proxy that is not connected to
2100
+ # with the domain of one of the partnered servers.
2101
+ packet_show_store_offer:
2102
+ !id: 0x5b
2103
+ !bound: client
2104
+ # OfferID is a string that identifies the offer for which a window should be opened. While typically a
2105
+ # UUID, the ID could be anything.
2106
+ offer_id: string
2107
+ # ShowAll specifies if all other offers of the same 'author' as the one of the offer associated with the
2108
+ # OfferID should also be displayed, alongside the target offer.
2109
+ show_all: bool
2110
+
2111
+
2112
+ # PurchaseReceipt is sent by the client to the server to notify the server it purchased an item from the
2113
+ # Marketplace store that was offered by the server. The packet is only used for partnered servers.
2114
+ packet_purchase_receipt:
2115
+ !id: 0x5c
2116
+ !bound: server
2117
+ # Receipts is a list of receipts, or proofs of purchases, for the offers that have been purchased by the
2118
+ # player.
2119
+ receipts: string[]varint
2120
+
2121
+ packet_player_skin:
2122
+ !id: 0x5d
2123
+ !bound: both
2124
+ uuid: uuid
2125
+ skin: Skin
2126
+ skin_name: string
2127
+ old_skin_name: string
2128
+ is_verified: bool
2129
+
2130
+ # SubClientLogin is sent when a sub-client joins the server while another client is already connected to it.
2131
+ # The packet is sent as a result of split-screen game play, and allows up to four players to play using the
2132
+ # same network connection. After an initial Login packet from the 'main' client, each sub-client that
2133
+ # connects sends a SubClientLogin to request their own login.
2134
+ packet_sub_client_login:
2135
+ !id: 0x5e
2136
+ !bound: client
2137
+ # ConnectionRequest is a string containing information about the player and JWTs that may be used to
2138
+ # verify if the player is connected to XBOX Live. The connection request also contains the necessary
2139
+ # client public key to initiate encryption.
2140
+ # The ConnectionRequest in this packet is identical to the one found in the Login packet.
2141
+ tokens: '["encapsulated", { "lengthType": "varint", "type": "LoginTokens" }]'
2142
+
2143
+ # AutomationClientConnect is used to make the client connect to a websocket server. This websocket server has
2144
+ # the ability to execute commands on the behalf of the client and it can listen for certain events fired by
2145
+ # the client.
2146
+ packet_initiate_web_socket_connection:
2147
+ !id: 0x5f
2148
+ !bound: client
2149
+ # ServerURI is the URI to make the client connect to. It can be, for example, 'localhost:8000/ws' to
2150
+ # connect to a websocket server on the localhost at port 8000.
2151
+ server: string
2152
+
2153
+
2154
+ # SetLastHurtBy is sent by the server to let the client know what entity type it was last hurt by. At this
2155
+ # moment, the packet is useless and should not be used. There is no behaviour that depends on if this
2156
+ # packet is sent or not.
2157
+ packet_set_last_hurt_by:
2158
+ !id: 0x60
2159
+ !bound: client
2160
+ entity_type: varint
2161
+
2162
+ # BookEdit is sent by the client when it edits a book. It is sent each time a modification was made and the
2163
+ # player stops its typing 'session', rather than simply after closing the book.
2164
+ packet_book_edit:
2165
+ !id: 0x61
2166
+ !bound: client
2167
+ type: u8 =>
2168
+ 0: replace_page
2169
+ 1: add_page
2170
+ 2: delete_page
2171
+ 3: swap_pages
2172
+ 4: sign
2173
+ slot: u8
2174
+ _: type?
2175
+ if replace_page or add_page:
2176
+ page_number: u8
2177
+ text: string
2178
+ # Only available on Education Edition.
2179
+ photo_name: string
2180
+ if delete_page:
2181
+ page_number: u8
2182
+ if swap_pages:
2183
+ page1: u8
2184
+ page2: u8
2185
+ if sign:
2186
+ title: string
2187
+ author: string
2188
+ xuid: string
2189
+
2190
+
2191
+ # NPCRequest is sent by the client when it interacts with an NPC.
2192
+ # The packet is specifically made for Education Edition, where NPCs are available to use.
2193
+ packet_npc_request:
2194
+ !id: 0x62
2195
+ !bound: both
2196
+ # EntityRuntimeID is the runtime ID of the NPC entity that the player interacted with. It is the same
2197
+ # as sent by the server when spawning the entity.
2198
+ runtime_entity_id: varint64
2199
+ # RequestType is the type of the request, which depends on the permission that the player has. It will
2200
+ # be either a type that indicates that the NPC should show its dialog, or that it should open the
2201
+ # editing window.
2202
+ request_type: u8 =>
2203
+ 0: set_actions
2204
+ 1: execute_action
2205
+ 2: execute_closing_commands
2206
+ 3: set_name
2207
+ 4: set_skin
2208
+ 5: set_interaction_text
2209
+ # CommandString is the command string set in the NPC. It may consist of multiple commands, depending on
2210
+ # what the player set in it.
2211
+ command: string
2212
+ # ActionType is the type of the action to execute.
2213
+ action_type: u8 =>
2214
+ 0: set_actions
2215
+ 1: execute_action
2216
+ 2: execute_closing_commands
2217
+ 3: set_name
2218
+ 4: set_skin
2219
+ 5: set_interact_text
2220
+ 6: execute_openining_commands
2221
+ # SceneName is the name of the scene.
2222
+ scene_name: string
2223
+
2224
+ # PhotoTransfer is sent by the server to transfer a photo (image) file to the client. It is typically used
2225
+ # to transfer photos so that the client can display it in a portfolio in Education Edition.
2226
+ # While previously usable in the default Bedrock Edition, the displaying of photos in books was disabled and
2227
+ # the packet now has little use anymore.
2228
+ packet_photo_transfer:
2229
+ !id: 0x63
2230
+ !bound: server
2231
+ # PhotoName is the name of the photo to transfer. It is the exact file name that the client will download
2232
+ # the photo as, including the extension of the file.
2233
+ image_name: string
2234
+ # PhotoData is the raw data of the photo image. The format of this data may vary: Formats such as JPEG or
2235
+ # PNG work, as long as PhotoName has the correct extension.
2236
+ image_data: string
2237
+ # BookID is the ID of the book that the photo is associated with. If the PhotoName in a book with this ID
2238
+ # is set to PhotoName, it will display the photo (provided Education Edition is used).
2239
+ # The photo image is downloaded to a sub-folder with this book ID.
2240
+ book_id: string
2241
+ # PhotoType is one of the three photo types above.
2242
+ photo_type: u8
2243
+ # SourceType is the source photo type. It is one of the three photo types above.
2244
+ source_type: u8
2245
+ # OwnerEntityUniqueID is the entity unique ID of the photo's owner.
2246
+ owner_entity_unique_id: li64
2247
+ # NewPhotoName is the new name of the photo.
2248
+ new_photo_name: string
2249
+
2250
+ # ModalFormRequest is sent by the server to make the client open a form. This form may be either a modal form
2251
+ # which has two options, a menu form for a selection of options and a custom form for properties.
2252
+ packet_modal_form_request:
2253
+ !id: 0x64
2254
+ !bound: client
2255
+ # FormID is an ID used to identify the form. The ID is saved by the client and sent back when the player
2256
+ # submits the form, so that the server can identify which form was submitted.
2257
+ form_id: varint
2258
+ # FormData is a JSON encoded object of form data. The content of the object differs, depending on the
2259
+ # type of the form sent, which is also set in the JSON.
2260
+ data: string
2261
+
2262
+ # ModalFormResponse is sent by the client in response to a ModalFormRequest, after the player has submitted
2263
+ # the form sent. It contains the options/properties selected by the player, or a JSON encoded 'null' if
2264
+ # the form was closed by clicking the X at the top right corner of the form.
2265
+ packet_modal_form_response:
2266
+ !id: 0x65
2267
+ !bound: server
2268
+ # FormID is the form ID of the form the client has responded to. It is the same as the ID sent in the
2269
+ # ModalFormRequest, and may be used to identify which form was submitted.
2270
+ form_id: varint
2271
+ # HasResponseData is true if the client provided response data.
2272
+ has_response_data: bool
2273
+ # ResponseData is a JSON encoded value representing the response of the player. For a modal form, the response is
2274
+ # either true or false, for a menu form, the response is an integer specifying the index of the button clicked, and
2275
+ # for a custom form, the response is an array containing a value for each element.
2276
+ data: has_response_data ?
2277
+ if true: string
2278
+ # HasCancelReason is true if the client provided a reason for the form being cancelled.
2279
+ has_cancel_reason: bool
2280
+ # CancelReason represents the reason why the form was cancelled.
2281
+ _: has_cancel_reason ?
2282
+ if true:
2283
+ cancel_reason: u8 =>
2284
+ 0: closed
2285
+ 1: busy
2286
+
2287
+ # ServerSettingsRequest is sent by the client to request the settings specific to the server. These settings
2288
+ # are shown in a separate tab client-side, and have the same structure as a custom form.
2289
+ # ServerSettingsRequest has no fields.
2290
+ packet_server_settings_request:
2291
+ !id: 0x66
2292
+ !bound: server
2293
+
2294
+ # ServerSettingsResponse is optionally sent by the server in response to a ServerSettingsRequest from the
2295
+ # client. It is structured the same as a ModalFormRequest packet, and if filled out correctly, will show
2296
+ # a specific tab for the server in the settings of the client. A ModalFormResponse packet is sent by the
2297
+ # client in response to a ServerSettingsResponse, when the client fills out the settings and closes the
2298
+ # settings again.
2299
+ packet_server_settings_response:
2300
+ !id: 0x67
2301
+ !bound: client
2302
+ # FormID is an ID used to identify the form. The ID is saved by the client and sent back when the player
2303
+ # submits the form, so that the server can identify which form was submitted.
2304
+ form_id: varint
2305
+ # FormData is a JSON encoded object of form data. The content of the object differs, depending on the
2306
+ # type of the form sent, which is also set in the JSON.
2307
+ data: string
2308
+
2309
+ # ShowProfile is sent by the server to show the XBOX Live profile of one player to another.
2310
+ packet_show_profile:
2311
+ !id: 0x68
2312
+ !bound: client
2313
+ # XUID is the XBOX Live User ID of the player whose profile should be shown to the player. If it is not
2314
+ # a valid XUID, the client ignores the packet.
2315
+ xuid: string
2316
+
2317
+ # SetDefaultGameType is sent by the client when it toggles the default game type in the settings UI, and is
2318
+ # sent by the server when it actually changes the default game type, resulting in the toggle being changed
2319
+ # in the settings UI.
2320
+ packet_set_default_game_type:
2321
+ !id: 0x69
2322
+ !bound: client
2323
+ # GameType is the new game type that is set. When sent by the client, this is the requested new default
2324
+ # game type.
2325
+ gamemode: GameMode
2326
+
2327
+ # RemoveObjective is sent by the server to remove a scoreboard objective. It is used to stop showing a
2328
+ # scoreboard to a player.
2329
+ packet_remove_objective:
2330
+ !id: 0x6a
2331
+ !bound: client
2332
+ # ObjectiveName is the name of the objective that the scoreboard currently active has. This name must
2333
+ # be identical to the one sent in the SetDisplayObjective packet.
2334
+ objective_name: string
2335
+
2336
+ # SetDisplayObjective is sent by the server to display an object as a scoreboard to the player. Once sent,
2337
+ # it should be followed up by a SetScore packet to set the lines of the packet.
2338
+ packet_set_display_objective:
2339
+ !id: 0x6b
2340
+ !bound: client
2341
+ # DisplaySlot is the slot in which the scoreboard should be displayed. Available options can be found in
2342
+ # the constants above.
2343
+ display_slot: string
2344
+ # ObjectiveName is the name of the objective that the scoreboard displays. Filling out a random unique
2345
+ # value for this field works: It is not displayed in the scoreboard.
2346
+ objective_name: string
2347
+ # DisplayName is the name, or title, that is displayed at the top of the scoreboard.
2348
+ display_name: string
2349
+ # CriteriaName is the name of the criteria that need to be fulfilled in order for the score to be
2350
+ # increased. This can be any kind of string and does not show up client-side.
2351
+ criteria_name: string
2352
+ # SortOrder is the order in which entries on the scoreboard should be sorted. It is one of the constants
2353
+ # that may be found above.
2354
+ sort_order: zigzag32
2355
+
2356
+ # SetScore is sent by the server to send the contents of a scoreboard to the player. It may be used to either
2357
+ # add, remove or edit entries on the scoreboard.
2358
+ packet_set_score:
2359
+ !id: 0x6c
2360
+ !bound: client
2361
+ # ActionType is the type of the action to execute upon the scoreboard with the entries that the packet
2362
+ # has. If ActionType is ScoreboardActionModify, all entries will be added to the scoreboard if not yet
2363
+ # present, or modified if already present. If set to ScoreboardActionRemove, all scoreboard entries set
2364
+ # will be removed from the scoreboard.
2365
+ action: u8 =>
2366
+ 0: change
2367
+ 1: remove
2368
+ entries: []varint
2369
+ scoreboard_id: zigzag64
2370
+ objective_name: string
2371
+ score: li32
2372
+ _: ../action ?
2373
+ if change:
2374
+ entry_type: i8 =>
2375
+ 1: player
2376
+ 2: entity
2377
+ 3: fake_player
2378
+ entity_unique_id: entry_type ?
2379
+ if player or entity: zigzag64
2380
+ custom_name: entry_type ?
2381
+ if fake_player: string
2382
+
2383
+ # LabTable is sent by the client to let the server know it started a chemical reaction in Education Edition,
2384
+ # and is sent by the server to other clients to show the effects.
2385
+ # The packet is only functional if Education features are enabled.
2386
+ packet_lab_table:
2387
+ !id: 0x6d
2388
+ !bound: both
2389
+ # ActionType is the type of the action that was executed. It is one of the constants above. Typically,
2390
+ # only LabTableActionCombine is sent by the client, whereas LabTableActionReact is sent by the server.
2391
+ action_type: u8 =>
2392
+ 0: combine
2393
+ 1: react
2394
+ # Position is the position at which the lab table used was located.
2395
+ position: vec3u
2396
+ # ReactionType is the type of the reaction that took place as a result of the items put into the lab
2397
+ # table. The reaction type can be either that of an item or a particle, depending on whatever the result
2398
+ # was of the reaction.
2399
+ reaction_type: u8
2400
+
2401
+ # UpdateBlockSynced is sent by the server to synchronise the falling of a falling block entity with the
2402
+ # transitioning back and forth from and to a solid block. It is used to prevent the entity from flickering,
2403
+ # and is used in places such as the pushing of blocks with pistons.
2404
+ packet_update_block_synced:
2405
+ !id: 0x6e
2406
+ !bound: client
2407
+ # Position is the block position at which a block is updated.
2408
+ position: BlockCoordinates
2409
+ # NewBlockRuntimeID is the runtime ID of the block that is placed at Position after sending the packet
2410
+ # to the client.
2411
+ block_runtime_id: varint
2412
+ # Flags is a combination of flags that specify the way the block is updated client-side. It is a
2413
+ # combination of the flags above, but typically sending only the BlockUpdateNetwork flag is sufficient.
2414
+ flags: UpdateBlockFlags
2415
+ # Layer is the world layer on which the block is updated. For most blocks, this is the first layer, as
2416
+ # that layer is the default layer to place blocks on, but for blocks inside of each other, this differs.
2417
+ layer: varint
2418
+ # EntityUniqueID is the unique ID of the falling block entity that the block transitions to or that the
2419
+ # entity transitions from.
2420
+ # Note that for both possible values for TransitionType, the EntityUniqueID should point to the falling
2421
+ # block entity involved.
2422
+ entity_unique_id: zigzag64
2423
+ # TransitionType is the type of the transition that happened. It is either BlockToEntityTransition, when
2424
+ # a block placed becomes a falling entity, or EntityToBlockTransition, when a falling entity hits the
2425
+ # ground and becomes a solid block again.
2426
+ transition_type: varint => TransitionType
2427
+
2428
+
2429
+ # MoveActorDelta is sent by the server to move an entity. The packet is specifically optimised to save as
2430
+ # much space as possible, by only writing non-zero fields.
2431
+ # As of 1.16.100, this packet no longer actually contains any deltas.
2432
+ packet_move_entity_delta:
2433
+ !id: 0x6f
2434
+ !bound: client
2435
+ # EntityRuntimeID is the runtime ID of the entity that is being moved. The packet works provided a
2436
+ # non-player entity with this runtime ID is present.
2437
+ runtime_entity_id: varint64
2438
+ # Flags is a list of flags that specify what data is in the packet.
2439
+ flags: DeltaMoveFlags
2440
+ x: flags.has_x?
2441
+ if true: lf32
2442
+ y: flags.has_y?
2443
+ if true: lf32
2444
+ z: flags.has_z?
2445
+ if true: lf32
2446
+ rot_x: flags.has_rot_x?
2447
+ if true: u8 # TODO: * implement ByteFloat
2448
+ rot_y: flags.has_rot_y?
2449
+ if true: u8
2450
+ rot_z: flags.has_rot_z?
2451
+ if true: u8
2452
+
2453
+ DeltaMoveFlags: [ "bitflags",
2454
+ {
2455
+ "type": "lu16",
2456
+ "flags": {
2457
+ "has_x": 0x01,
2458
+ "has_y": 0x02,
2459
+ "has_z": 0x04,
2460
+ "has_rot_x": 0x08,
2461
+ "has_rot_y": 0x10,
2462
+ "has_rot_z": 0x20,
2463
+ "on_ground": 0x40,
2464
+ "teleport": 0x80,
2465
+ "force_move": 0x100
2466
+ }
2467
+ }
2468
+ ]
2469
+
2470
+ # SetScoreboardIdentity is sent by the server to change the identity type of one of the entries on a
2471
+ # scoreboard. This is used to change, for example, an entry pointing to a player, to a fake player when it
2472
+ # leaves the server, and to change it back to a real player when it joins again.
2473
+ # In non-vanilla situations, the packet is quite useless.
2474
+ packet_set_scoreboard_identity:
2475
+ !id: 0x70
2476
+ !bound: client
2477
+ # ActionType is the type of the action to execute. The action is either ScoreboardIdentityActionRegister
2478
+ # to associate an identity with the entry, or ScoreboardIdentityActionClear to remove associations with
2479
+ # an entity.
2480
+ action: i8 =>
2481
+ 0: register_identity
2482
+ 1: clear_identity
2483
+ # Entries is a list of all entries in the packet. Each of these entries points to one of the entries on
2484
+ # a scoreboard. Depending on ActionType, their identity will either be registered or cleared.
2485
+ entries: []varint
2486
+ scoreboard_id: zigzag64
2487
+ entity_unique_id: ../action ?
2488
+ if register_identity: zigzag64
2489
+ default: void
2490
+
2491
+
2492
+ # SetLocalPlayerAsInitialised is sent by the client in response to a PlayStatus packet with the status set
2493
+ # to spawn. The packet marks the moment at which the client is fully initialised and can receive any packet
2494
+ # without discarding it.
2495
+ packet_set_local_player_as_initialized:
2496
+ !id: 0x71
2497
+ !bound: server
2498
+ # EntityRuntimeID is the entity runtime ID the player was assigned earlier in the login sequence in the
2499
+ # StartGame packet.
2500
+ runtime_entity_id: varint64
2501
+
2502
+ packet_update_soft_enum:
2503
+ !id: 0x72
2504
+ !bound: client
2505
+
2506
+ # NetworkStackLatency is sent by the server (and the client, on development builds) to measure the latency
2507
+ # over the entire Minecraft stack, rather than the RakNet latency. It has other usages too, such as the
2508
+ # ability to be used as some kind of acknowledgement packet, to know when the client has received a certain
2509
+ # other packet.
2510
+ packet_network_stack_latency:
2511
+ !id: 0x73
2512
+ !bound: both
2513
+ # Timestamp is the timestamp of the network stack latency packet. The client will, if NeedsResponse is
2514
+ # set to true, send a NetworkStackLatency packet with this same timestamp packet in response.
2515
+ timestamp: lu64
2516
+ # NeedsResponse specifies if the sending side of this packet wants a response to the packet, meaning that
2517
+ # the other side should send a NetworkStackLatency packet back.
2518
+ needs_response: u8
2519
+
2520
+ # ScriptCustomEvent is sent by both the client and the server. It is a way to let scripts communicate with
2521
+ # the server, so that the client can let the server know it triggered an event, or the other way around.
2522
+ # It is essentially an RPC kind of system.
2523
+ packet_script_custom_event:
2524
+ !id: 0x75
2525
+ !bound: both
2526
+ # EventName is the name of the event. The script and the server will use this event name to identify the
2527
+ # data that is sent.
2528
+ event_name: string
2529
+ # EventData is the data of the event. This data is typically a JSON encoded string, that the script is
2530
+ # able to encode and decode too.
2531
+ event_data: string
2532
+
2533
+ # SpawnParticleEffect is sent by the server to spawn a particle effect client-side. Unlike other packets that
2534
+ # result in the appearing of particles, this packet can show particles that are not hardcoded in the client.
2535
+ # They can be added and changed through behaviour packs to implement custom particles.
2536
+ packet_spawn_particle_effect:
2537
+ !id: 0x76
2538
+ !bound: client
2539
+ # Dimension is the dimension that the particle is spawned in. Its exact usage is not clear, as the
2540
+ # dimension has no direct effect on the particle.
2541
+ dimension: u8
2542
+ # EntityUniqueID is the unique ID of the entity that the spawned particle may be attached to. If this ID
2543
+ # is not -1, the Position below will be interpreted as relative to the position of the entity associated
2544
+ # with this unique ID.
2545
+ entity_id: zigzag64
2546
+ # Position is the position that the particle should be spawned at. If the position is too far away from
2547
+ # the player, it will not show up.
2548
+ # If EntityUniqueID is not -1, the position will be relative to the position of the entity.
2549
+ position: vec3f
2550
+ # ParticleName is the name of the particle that should be shown. This name may point to a particle effect
2551
+ # that is built-in, or to one implemented by behaviour packs.
2552
+ particle_name: string
2553
+ # MoLangVariables is an encoded JSON map of MoLang variables that may be applicable to the particle spawn. This can
2554
+ # just be left empty in most cases.
2555
+ # TODO: Investigate, probably not a ByteArray...
2556
+ molang_variables: ByteArray
2557
+
2558
+ # AvailableActorIdentifiers is sent by the server at the start of the game to let the client know all
2559
+ # entities that are available on the server.
2560
+ packet_available_entity_identifiers:
2561
+ !id: 0x77
2562
+ !bound: client
2563
+ # SerialisedEntityIdentifiers is a network NBT serialised compound of all entity identifiers that are
2564
+ # available in the server.
2565
+ nbt: nbt
2566
+
2567
+ # Not used. Use `packet_level_sound_event`.
2568
+ packet_level_sound_event_v2:
2569
+ !id: 0x78
2570
+ !bound: both
2571
+ sound_id: u8
2572
+ position: vec3f
2573
+ block_id: zigzag32
2574
+ entity_type: string
2575
+ is_baby_mob: bool
2576
+ is_global: bool
2577
+
2578
+ # NetworkChunkPublisherUpdate is sent by the server to change the point around which chunks are and remain
2579
+ # loaded. This is useful for mini-game servers, where only one area is ever loaded, in which case the
2580
+ # NetworkChunkPublisherUpdate packet can be sent in the middle of it, so that no chunks ever need to be
2581
+ # additionally sent during the course of the game.
2582
+ # In reality, the packet is not extraordinarily useful, and most servers just send it constantly at the
2583
+ # position of the player.
2584
+ # If the packet is not sent at all, no chunks will be shown to the player, regardless of where they are sent.
2585
+ packet_network_chunk_publisher_update:
2586
+ !id: 0x79
2587
+ !bound: client
2588
+ # Position is the block position around which chunks loaded will remain shown to the client. Most servers
2589
+ # set this position to the position of the player itself.
2590
+ coordinates: BlockCoordinates
2591
+ # Radius is the radius in blocks around Position that chunks sent show up in and will remain loaded in.
2592
+ # Unlike the RequestChunkRadius and ChunkRadiusUpdated packets, this radius is in blocks rather than
2593
+ # chunks, so the chunk radius needs to be multiplied by 16. (Or shifted to the left by 4.)
2594
+ radius: varint
2595
+ saved_chunks: []lu32
2596
+ # ChunkX is the X coordinate of the chunk sent. (To translate a block's X to a chunk's X: x >> 4)
2597
+ x: zigzag32
2598
+ # ChunkZ is the Z coordinate of the chunk sent. (To translate a block's Z to a chunk's Z: z >> 4)
2599
+ z: zigzag32
2600
+
2601
+
2602
+ # BiomeDefinitionList is sent by the server to let the client know all biomes that are available and
2603
+ # implemented on the server side. It is much like the AvailableActorIdentifiers packet, but instead
2604
+ # functions for biomes.
2605
+ packet_biome_definition_list:
2606
+ !id: 0x7a
2607
+ !bound: client
2608
+ # SerialisedBiomeDefinitions is a network NBT serialised compound of all definitions of biomes that are
2609
+ # available on the server.
2610
+ nbt: nbt
2611
+
2612
+ # LevelSoundEvent is sent by the server to make any kind of built-in sound heard to a player. It is sent to,
2613
+ # for example, play a stepping sound or a shear sound. The packet is also sent by the client, in which case
2614
+ # it could be forwarded by the server to the other players online. If possible, the packets from the client
2615
+ # should be ignored however, and the server should play them on its own accord.
2616
+ packet_level_sound_event:
2617
+ !id: 0x7b
2618
+ !bound: both
2619
+ # SoundType is the type of the sound to play. Some of the sound types
2620
+ # require additional data, which is set in the EventData field.
2621
+ sound_id: SoundType
2622
+ # Position is the position of the sound event. The player will be able to hear the direction of the sound
2623
+ # based on what position is sent here.
2624
+ position: vec3f
2625
+ # ExtraData is a packed integer that some sound types use to provide extra data. An example of this is
2626
+ # the note sound, which is composed of a pitch and an instrument type.
2627
+ extra_data: zigzag32
2628
+ # EntityType is the string entity type of the entity that emitted the sound, for example
2629
+ # 'minecraft:skeleton'. Some sound types use this entity type for additional data.
2630
+ entity_type: string
2631
+ # BabyMob specifies if the sound should be that of a baby mob. It is most notably used for parrot
2632
+ # imitations, which will change based on if this field is set to true or not.
2633
+ is_baby_mob: bool
2634
+ # DisableRelativeVolume specifies if the sound should be played relatively or not. If set to true, the
2635
+ # sound will have full volume, regardless of where the Position is, whereas if set to false, the sound's
2636
+ # volume will be based on the distance to Position.
2637
+ is_global: bool
2638
+
2639
+ # LevelEventGeneric is sent by the server to send a 'generic' level event to the client. This packet sends an
2640
+ # NBT serialised object and may for that reason be used for any event holding additional data.
2641
+ packet_level_event_generic:
2642
+ !id: 0x7c
2643
+ !bound: client
2644
+ # EventID is a unique identifier that identifies the event called. The data that follows has fields in
2645
+ # the NBT depending on what event it is.
2646
+ event_id: varint
2647
+ # SerialisedEventData is a network little endian serialised object of event data, with fields that vary
2648
+ # depending on EventID.
2649
+ # Unlike many other NBT structures, this data is not actually in a compound but just loosely floating
2650
+ # NBT tags. To decode using the nbt package, you would need to append 0x0a00 at the start (compound id
2651
+ # and name length) and add 0x00 at the end, to manually wrap it in a compound. Likewise, you would have
2652
+ # to remove these bytes when encoding.
2653
+ nbt: nbtLoop
2654
+
2655
+ # LecternUpdate is sent by the client to update the server on which page was opened in a book on a lectern,
2656
+ # or if the book should be removed from it.
2657
+ packet_lectern_update:
2658
+ !id: 0x7d
2659
+ !bound: client
2660
+ # Page is the page number in the book that was opened by the player on the lectern.
2661
+ page: u8
2662
+ # PageCount is the number of pages that the book opened in the lectern has.
2663
+ page_count: u8
2664
+ # Position is the position of the lectern that was updated. If no lectern is at the block position,
2665
+ # the packet should be ignored.
2666
+ position: vec3i
2667
+ # DropBook specifies if the book currently set on display in the lectern should be dropped server-side.
2668
+ drop_book: bool
2669
+
2670
+ # This packet was removed.
2671
+ packet_video_stream_connect:
2672
+ !id: 0x7e
2673
+ !bound: client
2674
+ server_uri: string
2675
+ frame_send_frequency: lf32
2676
+ action: u8
2677
+ resolution_x: li32
2678
+ resolution_y: li32
2679
+
2680
+ # This is NOT a Minecraft entity, but an entity in the Entity Component System (ECS)
2681
+ # for the game engine Minecrat Bedrock uses. Internally, all 'Minecraft entities' are
2682
+ # known as Actors including in packet names and fields. However, these are irrelevant
2683
+ # internal details so we don't do the renames in these protocol definitions, for simplicity we just use Entity.
2684
+ #
2685
+ # AddEntity is sent by the server to the client. Its function is not entirely clear: It does not add an
2686
+ # entity in the sense of an in-game entity, but has to do with the ECS that Minecraft uses.
2687
+ packet_add_ecs_entity:
2688
+ !id: 0x7f
2689
+ !bound: client
2690
+ # EntityNetworkID is the network ID of the entity that should be added.
2691
+ network_id: varint64
2692
+
2693
+ # RemoveEntity is sent by the server to the client. Its function is not entirely clear: It does not remove an
2694
+ # entity in the sense of an in-game entity, but has to do with the ECS that Minecraft uses
2695
+ packet_remove_ecs_entity:
2696
+ !id: 0x80
2697
+ !bound: client
2698
+ # EntityNetworkID is the network ID of the entity that should be removed.
2699
+ network_id: varint64
2700
+
2701
+ # ClientCacheStatus is sent by the client to the server at the start of the game. It is sent to let the
2702
+ # server know if it supports the client-side blob cache. Clients such as Nintendo Switch do not support the
2703
+ # cache, and attempting to use it anyway will fail.
2704
+ packet_client_cache_status:
2705
+ !id: 0x81
2706
+ !bound: both
2707
+ # Enabled specifies if the blob cache is enabled. If false, the server should not attempt to use the
2708
+ # blob cache. If true, it may do so, but it may also choose not to use it.
2709
+ enabled: bool
2710
+
2711
+ # OnScreenTextureAnimation is sent by the server to show a certain animation on the screen of the player.
2712
+ # The packet is used, as an example, for when a raid is triggered and when a raid is defeated.
2713
+ packet_on_screen_texture_animation:
2714
+ !id: 0x82
2715
+ !bound: client
2716
+ # AnimationType is the type of the animation to show. The packet provides no further extra data to allow
2717
+ # modifying the duration or other properties of the animation.
2718
+ animation_type: lu32
2719
+
2720
+
2721
+ # MapCreateLockedCopy is sent by the server to create a locked copy of one map into another map. In vanilla,
2722
+ # it is used in the cartography table to create a map that is locked and cannot be modified.
2723
+ packet_map_create_locked_copy:
2724
+ !id: 0x83
2725
+ !bound: client
2726
+ # OriginalMapID is the ID of the map that is being copied. The locked copy will obtain all content that
2727
+ # is visible on this map, except the content will not change.
2728
+ original_map_id: zigzag64
2729
+ # NewMapID is the ID of the map that holds the locked copy of the map that OriginalMapID points to. Its
2730
+ # contents will be impossible to change.
2731
+ new_map_id: zigzag64
2732
+
2733
+
2734
+ # StructureTemplateDataRequest is sent by the client to request data of a structure.
2735
+ packet_structure_template_data_export_request:
2736
+ !id: 0x84
2737
+ !bound: client
2738
+ # StructureName is the name of the structure that was set in the structure block's UI. This is the name
2739
+ # used to export the structure to a file.
2740
+ name: string
2741
+ # Position is the position of the structure block that has its template data requested.
2742
+ position: BlockCoordinates
2743
+ # Settings is a struct of settings that should be used for exporting the structure. These settings are
2744
+ # identical to the last sent in the StructureBlockUpdate packet by the client.
2745
+ settings: StructureBlockSettings
2746
+ # RequestType specifies the type of template data request that the player sent.
2747
+ request_type: u8 =>
2748
+ 1: export_from_save
2749
+ 2: export_from_load
2750
+ 3: query_saved_structure
2751
+ 4: import_from_save
2752
+
2753
+ # StructureTemplateDataResponse is sent by the server to send data of a structure to the client in response
2754
+ # to a StructureTemplateDataRequest packet.
2755
+ packet_structure_template_data_export_response:
2756
+ !id: 0x85
2757
+ !bound: client
2758
+ name: string
2759
+ success: bool
2760
+ nbt: success ?
2761
+ if true: nbt
2762
+ # ResponseType specifies the response type of the packet. This depends on the RequestType field sent in
2763
+ # the StructureTemplateDataRequest packet and is one of the constants above.
2764
+ response_type: u8 =>
2765
+ 1: export
2766
+ 2: query
2767
+ 3: import
2768
+
2769
+ # No longer used.
2770
+ packet_update_block_properties:
2771
+ !id: 0x86
2772
+ !bound: client
2773
+ nbt: nbt
2774
+
2775
+ # ClientCacheBlobStatus is part of the blob cache protocol. It is sent by the client to let the server know
2776
+ # what blobs it needs and which blobs it already has, in an ACK type system.
2777
+ packet_client_cache_blob_status:
2778
+ !id: 0x87
2779
+ !bound: client
2780
+ # The number of MISSes in this packet
2781
+ misses: varint
2782
+ # The number of HITs in this packet
2783
+ haves: varint
2784
+ # A list of blob hashes that the client does not have a blob available for. The server
2785
+ # should send the blobs matching these hashes as soon as possible.
2786
+ missing: lu64[]$misses
2787
+ # A list of hashes that the client does have a cached blob for. Server doesn't need to send.
2788
+ have: lu64[]$haves
2789
+
2790
+ # ClientCacheMissResponse is part of the blob cache protocol. It is sent by the server in response to a
2791
+ # ClientCacheBlobStatus packet and contains the blob data of all blobs that the client acknowledged not to
2792
+ # have yet.
2793
+ packet_client_cache_miss_response:
2794
+ !id: 0x88
2795
+ !bound: client
2796
+ blobs: Blob[]varint
2797
+
2798
+ # EducationSettings is a packet sent by the server to update Minecraft: Education Edition related settings.
2799
+ # It is unused by the normal base game.
2800
+ packet_education_settings:
2801
+ !id: 0x89
2802
+ !bound: client
2803
+ # CodeBuilderDefaultURI is the default URI that the code builder is ran on. Using this, a Code Builder
2804
+ # program can make code directly affect the server.
2805
+ CodeBuilderDefaultURI: string
2806
+ # CodeBuilderTitle is the title of the code builder shown when connected to the CodeBuilderDefaultURI.
2807
+ CodeBuilderTitle: string
2808
+ # CanResizeCodeBuilder specifies if clients connected to the world should be able to resize the code
2809
+ # builder when it is opened.
2810
+ CanResizeCodeBuilder: bool
2811
+ disable_legacy_title_bar: bool
2812
+ post_process_filter: string
2813
+ screenshot_border_path: string
2814
+ has_agent_capabilities: bool
2815
+ agent_capabilities: has_agent_capabilities ?
2816
+ if true:
2817
+ has: bool
2818
+ can_modify_blocks: bool
2819
+ HasOverrideURI: bool
2820
+ OverrideURI: HasOverrideURI?
2821
+ if true: string
2822
+ # HasQuiz specifies if the world has a quiz connected to it.
2823
+ HasQuiz: bool
2824
+ has_external_link_settings: bool
2825
+ external_link_settings: has_external_link_settings ?
2826
+ has: bool
2827
+ url: string
2828
+ display_name: string
2829
+
2830
+ # Emote is sent by both the server and the client. When the client sends an emote, it sends this packet to
2831
+ # the server, after which the server will broadcast the packet to other players online.
2832
+ packet_emote:
2833
+ !id: 0x8a
2834
+ !bound: both
2835
+ # EntityRuntimeID is the entity that sent the emote. When a player sends this packet, it has this field
2836
+ # set as its own entity runtime ID.
2837
+ entity_id: varint64
2838
+ # EmoteID is the ID of the emote to send.
2839
+ emote_id: string
2840
+ # Flags is a combination of flags that change the way the Emote packet operates. When the server sends
2841
+ # this packet to other players, EmoteFlagServerSide must be present.
2842
+ flags: u8 =>
2843
+ 1: server_side
2844
+ 2: mute_chat
2845
+
2846
+ # MultiPlayerSettings is sent by the client to update multi-player related settings server-side and sent back
2847
+ # to online players by the server.
2848
+ # The MultiPlayerSettings packet is a Minecraft: Education Edition packet. It has no functionality for the
2849
+ # base game.
2850
+ packet_multiplayer_settings:
2851
+ !id: 0x8b
2852
+ !bound: server
2853
+ # ActionType is the action that should be done when this packet is sent. It is one of the constants that
2854
+ # may be found above.
2855
+ action_type: zigzag32 =>
2856
+ 0: enable_multiplayer
2857
+ 1: disable_multiplayer
2858
+ 2: refresh_join_code
2859
+
2860
+ # SettingsCommand is sent by the client when it changes a setting in the settings that results in the issuing
2861
+ # of a command to the server, such as when Show Coordinates is enabled.
2862
+ packet_settings_command:
2863
+ !id: 0x8c
2864
+ !bound: server
2865
+ # CommandLine is the full command line that was sent to the server as a result of the setting that the
2866
+ # client changed.
2867
+ command_line: string
2868
+ # SuppressOutput specifies if the client requests the suppressing of the output of the command that was
2869
+ # executed. Generally this is set to true, as the client won't need a message to confirm the output of
2870
+ # the change.
2871
+ suppress_output: bool
2872
+
2873
+ # AnvilDamage is sent by the client to request the dealing damage to an anvil. This packet is completely
2874
+ # pointless and the server should never listen to it.
2875
+ packet_anvil_damage:
2876
+ !id: 0x8d
2877
+ !bound: server
2878
+ # Damage is the damage that the client requests to be dealt to the anvil.
2879
+ damage: u8
2880
+ # AnvilPosition is the position in the world that the anvil can be found at.
2881
+ position: BlockCoordinates
2882
+
2883
+ # CompletedUsingItem is sent by the server to tell the client that it should be done using the item it is
2884
+ # currently using.
2885
+ packet_completed_using_item:
2886
+ !id: 0x8e
2887
+ !bound: client
2888
+ # UsedItemID is the item ID of the item that the client completed using. This should typically be the
2889
+ # ID of the item held in the hand.
2890
+ used_item_id: li16
2891
+ # UseMethod is the method of the using of the item that was completed. It is one of the constants that
2892
+ # may be found above.
2893
+ use_method: li32 =>
2894
+ 0: equip_armor
2895
+ 1: eat
2896
+ 2: attack
2897
+ 3: consume
2898
+ 4: throw
2899
+ 5: shoot
2900
+ 6: place
2901
+ 7: fill_bottle
2902
+ 8: fill_bucket
2903
+ 9: pour_bucket
2904
+ 10: use_tool
2905
+ 11: interact
2906
+ 12: retrieved
2907
+ 13: dyed
2908
+ 14: traded
2909
+
2910
+ # NetworkSettings is sent by the server to update a variety of network settings. These settings modify the
2911
+ # way packets are sent over the network stack.
2912
+ packet_network_settings:
2913
+ !id: 0x8f
2914
+ !bound: client
2915
+ # CompressionThreshold is the minimum size of a packet that is compressed when sent. If the size of a
2916
+ # packet is under this value, it is not compressed.
2917
+ # When set to 0, all packets will be left uncompressed.
2918
+ compression_threshold: lu16
2919
+ # CompressionAlgorithm is the algorithm that is used to compress packets.
2920
+ compression_algorithm: lu16 =>
2921
+ 0: deflate
2922
+ 1: snappy
2923
+ # ClientThrottle regulates whether the client should throttle players when exceeding of the threshold. Players
2924
+ # outside threshold will not be ticked, improving performance on low-end devices.
2925
+ client_throttle: bool
2926
+ # ClientThrottleThreshold is the threshold for client throttling. If the number of players exceeds this value, the
2927
+ # client will throttle players.
2928
+ client_throttle_threshold: u8
2929
+ # ClientThrottleScalar is the scalar for client throttling. The scalar is the amount of players that are ticked
2930
+ # when throttling is enabled.
2931
+ client_throttle_scalar: lf32
2932
+
2933
+ # PlayerAuthInput is sent by the client to allow for server authoritative movement. It is used to synchronise
2934
+ # the player input with the position server-side.
2935
+ # The client sends this packet when the ServerAuthoritativeMovementMode field in the StartGame packet is set
2936
+ # to true, instead of the MovePlayer packet. The client will send this packet once every tick.
2937
+ packet_player_auth_input:
2938
+ !id: 0x90
2939
+ !bound: server
2940
+ # Pitch that the player reports it has.
2941
+ pitch: lf32
2942
+ # Yaw that player reports it has.
2943
+ yaw: lf32
2944
+ # Position holds the position that the player reports it has.
2945
+ position: vec3f
2946
+ # MoveVector is a Vec2 that specifies the direction in which the player moved, as a combination of X/Z
2947
+ # values which are created using the WASD/controller stick state.
2948
+ move_vector: vec2f
2949
+ # HeadYaw is the horizontal rotation of the head that the player reports it has.
2950
+ head_yaw: lf32
2951
+ # InputData is a combination of bit flags that together specify the way the player moved last tick. It
2952
+ # is a combination of the flags above.
2953
+ input_data: InputFlag
2954
+ # InputMode specifies the way that the client inputs data to the screen. It is one of the constants that
2955
+ # may be found above.
2956
+ input_mode: varint =>
2957
+ 0: unknown
2958
+ 1: mouse
2959
+ 2: touch
2960
+ 3: game_pad
2961
+ 4: motion_controller
2962
+ # PlayMode specifies the way that the player is playing. The values it holds, which are rather random,
2963
+ # may be found above.
2964
+ play_mode: varint =>
2965
+ 0: normal
2966
+ 1: teaser
2967
+ 2: screen
2968
+ 3: viewer
2969
+ 4: reality
2970
+ 5: placement
2971
+ 6: living_room
2972
+ 7: exit_level
2973
+ 8: exit_level_living_room
2974
+ 9: num_modes
2975
+ # InteractionModel is a constant representing the interaction model the player is using.
2976
+ interaction_model: zigzag32 =>
2977
+ - touch
2978
+ - crosshair
2979
+ - classic
2980
+ # GazeDirection is the direction in which the player is gazing, when the PlayMode is PlayModeReality: In
2981
+ # other words, when the player is playing in virtual reality.
2982
+ gaze_direction: play_mode ?
2983
+ if reality: vec3f
2984
+ # Tick is the server tick at which the packet was sent. It is used in relation to
2985
+ # CorrectPlayerMovePrediction.
2986
+ tick: varint64
2987
+ # Delta was the delta between the old and the new position. There isn't any practical use for this field
2988
+ # as it can be calculated by the server itself.
2989
+ delta: vec3f
2990
+ transaction: input_data.item_interact ?
2991
+ if true:
2992
+ legacy: TransactionLegacy
2993
+ actions: TransactionActions
2994
+ data: TransactionUseItem
2995
+ item_stack_request: input_data.item_stack_request ?
2996
+ if true: ItemStackRequest
2997
+ block_action: input_data.block_action ?
2998
+ if true: []zigzag32
2999
+ action: Action
3000
+ _: action?
3001
+ if start_break or abort_break or crack_break or predict_break or continue_break:
3002
+ # BlockPosition is the position of the target block, if the action with the ActionType set concerned a
3003
+ # block. If that is not the case, the block position will be zero.
3004
+ position: BlockCoordinates
3005
+ # BlockFace is the face of the target block that was touched. If the action with the ActionType set
3006
+ # concerned a block. If not, the face is always 0.
3007
+ face: zigzag32
3008
+
3009
+ #TODO: update to use the new `shift` option in bitflags
3010
+ InputFlag: [ "bitflags", {
3011
+ "type": "varint64", "big": true,
3012
+ "flags": [
3013
+ "ascend",
3014
+ "descend",
3015
+ "north_jump",
3016
+ "jump_down",
3017
+ "sprint_down",
3018
+ "change_height",
3019
+ "jumping",
3020
+ "auto_jumping_in_water",
3021
+ "sneaking",
3022
+ "sneak_down",
3023
+ "up",
3024
+ "down",
3025
+ "left",
3026
+ "right",
3027
+ "up_left",
3028
+ "up_right",
3029
+ "want_up",
3030
+ "want_down",
3031
+ "want_down_slow",
3032
+ "want_up_slow",
3033
+ "sprinting",
3034
+ "ascend_block",
3035
+ "descend_block",
3036
+ "sneak_toggle_down",
3037
+ "persist_sneak",
3038
+ "start_sprinting",
3039
+ "stop_sprinting",
3040
+ "start_sneaking",
3041
+ "stop_sneaking",
3042
+ "start_swimming",
3043
+ "stop_swimming",
3044
+ "start_jumping",
3045
+ "start_gliding",
3046
+ "stop_gliding",
3047
+ "item_interact",
3048
+ "block_action",
3049
+ "item_stack_request",
3050
+ "handled_teleport"
3051
+ ]
3052
+ }]
3053
+
3054
+ # CreativeContent is a packet sent by the server to set the creative inventory's content for a player.
3055
+ # Introduced in 1.16, this packet replaces the previous method - sending an InventoryContent packet with
3056
+ # creative inventory window ID.
3057
+ # As of v1.16.100, this packet must be sent during the login sequence. Not sending it will stop the client
3058
+ # from joining the server.
3059
+ packet_creative_content:
3060
+ !id: 0x91
3061
+ !bound: client
3062
+ # Items is a list of the items that should be added to the creative inventory.
3063
+ items: []varint
3064
+ entry_id: varint
3065
+ item: ItemLegacy
3066
+
3067
+ # PlayerEnchantOptions is sent by the server to update the enchantment options displayed when the user opens
3068
+ # the enchantment table and puts an item in. This packet was added in 1.16 and allows the server to decide on
3069
+ # the enchantments that can be selected by the player.
3070
+ # The PlayerEnchantOptions packet should be sent once for every slot update of the enchantment table. The
3071
+ # vanilla server sends an empty PlayerEnchantOptions packet when the player opens the enchantment table
3072
+ # (air is present in the enchantment table slot) and sends the packet with actual enchantments in it when
3073
+ # items are put in that can have enchantments.
3074
+ packet_player_enchant_options:
3075
+ !id: 0x92
3076
+ !bound: client
3077
+ # Options is a list of possible enchantment options for the item that was put into the enchantment table.
3078
+ options: EnchantOption[]varint
3079
+
3080
+ # ItemStackRequest is sent by the client to change item stacks in an inventory. It is essentially a
3081
+ # replacement of the InventoryTransaction packet added in 1.16 for inventory specific actions, such as moving
3082
+ # items around or crafting. The InventoryTransaction packet is still used for actions such as placing blocks
3083
+ # and interacting with entities.
3084
+ packet_item_stack_request:
3085
+ !id: 0x93
3086
+ !bound: server
3087
+ requests: ItemStackRequest[]varint
3088
+
3089
+ # ItemStackResponse is sent by the server in response to an ItemStackRequest packet from the client. This
3090
+ # packet is used to either approve or reject ItemStackRequests from the client. If a request is approved, the
3091
+ # client will simply continue as normal. If rejected, the client will undo the actions so that the inventory
3092
+ # should be in sync with the server again.
3093
+ packet_item_stack_response:
3094
+ !id: 0x94
3095
+ !bound: client
3096
+ # Responses is a list of responses to ItemStackRequests sent by the client before. Responses either
3097
+ # approve or reject a request from the client.
3098
+ # Vanilla limits the size of this slice to 4096.
3099
+ responses: ItemStackResponses
3100
+
3101
+ # PlayerArmourDamage is sent by the server to damage the armour of a player. It is a very efficient packet,
3102
+ # but generally it's much easier to just send a slot update for the damaged armour.
3103
+ packet_player_armor_damage:
3104
+ !id: 0x95
3105
+ !bound: client
3106
+ # Bitset holds a bitset of 4 bits that indicate which pieces of armour need to have damage dealt to them.
3107
+ # The first bit, when toggled, is for a helmet, the second for the chestplate, the third for the leggings
3108
+ # and the fourth for boots.
3109
+ type: ArmorDamageType
3110
+ helmet_damage: type.head ?
3111
+ if true: zigzag32
3112
+ chestplate_damage: type.chest ?
3113
+ if true: zigzag32
3114
+ leggings_damage: type.legs ?
3115
+ if true: zigzag32
3116
+ boots_damage: type.feet ?
3117
+ if true: zigzag32
3118
+
3119
+ ArmorDamageType: [ "bitflags",
3120
+ {
3121
+ "type": "u8",
3122
+ "flags": {
3123
+ "head": 0b1,
3124
+ "chest": 0b10,
3125
+ "legs": 0b100,
3126
+ "feet": 0b1000
3127
+ }
3128
+ }
3129
+ ]
3130
+
3131
+ # UpdatePlayerGameType is sent by the server to change the game mode of a player. It is functionally
3132
+ # identical to the SetPlayerGameType packet.
3133
+ packet_update_player_game_type:
3134
+ !id: 0x97
3135
+ !bound: server
3136
+ # GameType is the new game type of the player. It is one of the constants that can be found in
3137
+ # set_player_game_type.go. Some of these game types require additional flags to be set in an
3138
+ # AdventureSettings packet for the game mode to obtain its full functionality.
3139
+ gamemode: GameMode
3140
+ # PlayerUniqueID is the entity unique ID of the player that should have its game mode updated. If this
3141
+ # packet is sent to other clients with the player unique ID of another player, nothing happens.
3142
+ player_unique_id: zigzag64
3143
+
3144
+
3145
+ # EmoteList is sent by the client every time it joins the server and when it equips new emotes. It may be
3146
+ # used by the server to find out which emotes the client has available. If the player has no emotes equipped,
3147
+ # this packet is not sent.
3148
+ # Under certain circumstances, this packet is also sent from the server to the client, but I was unable to
3149
+ # find when this is done.
3150
+ packet_emote_list:
3151
+ !id: 0x98
3152
+ !bound: server
3153
+ # PlayerRuntimeID is the runtime ID of the player that owns the emote pieces below. If sent by the
3154
+ # client, this player runtime ID is always that of the player itself.
3155
+ player_id: varint64
3156
+ # EmotePieces is a list of emote pieces that the player with the runtime ID above has.
3157
+ emote_pieces: uuid[]varint
3158
+
3159
+ # PositionTrackingDBClientRequest is a packet sent by the client to request the position and dimension of a
3160
+ # 'tracking ID'. These IDs are tracked in a database by the server. In 1.16, this is used for lodestones.
3161
+ # The client will send this request to find the position a lodestone compass needs to point to. If found, it
3162
+ # will point to the lodestone. If not, it will start spinning around.
3163
+ # A PositionTrackingDBServerBroadcast packet should be sent in response to this packet.
3164
+ packet_position_tracking_db_request:
3165
+ !id: 0x9a
3166
+ !bound: server
3167
+ # RequestAction is the action that should be performed upon the receiving of the packet. It is one of the
3168
+ # constants found above.
3169
+ action: u8 =>
3170
+ 0: query
3171
+ # TrackingID is a unique ID used to identify the request. The server responds with a
3172
+ # PositionTrackingDBServerBroadcast packet holding the same ID, so that the client can find out what that
3173
+ # packet was in response to.
3174
+ tracking_id: zigzag32
3175
+
3176
+ # PositionTrackingDBServerBroadcast is sent by the server in response to the
3177
+ # PositionTrackingDBClientRequest packet. This packet is, as of 1.16, currently only used for lodestones. The
3178
+ # server maintains a database with tracking IDs and their position and dimension. The client will request
3179
+ # these tracking IDs, (NBT tag set on the lodestone compass with the tracking ID?) and the server will
3180
+ # respond with the status of those tracking IDs.
3181
+ # What is actually done with the data sent depends on what the client chooses to do with it. For the
3182
+ # lodestone compass, it is used to make the compass point towards lodestones and to make it spin if the
3183
+ # lodestone at a position is no longer there.
3184
+ packet_position_tracking_db_broadcast:
3185
+ !id: 0x99
3186
+ !bound: client
3187
+ # BroadcastAction specifies the status of the position tracking DB response. It is one of the constants
3188
+ # above, specifying the result of the request with the ID below.
3189
+ # The Update action is sent for setting the position of a lodestone compass, the Destroy and NotFound to
3190
+ # indicate that there is not (no longer) a lodestone at that position.
3191
+ broadcast_action: u8 =>
3192
+ 0: update
3193
+ 1: destory
3194
+ 2: not_found
3195
+ # TrackingID is the ID of the PositionTrackingDBClientRequest packet that this packet was in response to.
3196
+ # The tracking ID is also present as the 'id' field in the SerialisedData field.
3197
+ tracking_id: zigzag32
3198
+ nbt: nbt
3199
+
3200
+ # PacketViolationWarning is sent by the client when it receives an invalid packet from the server. It holds
3201
+ # some information on the error that occurred.
3202
+ packet_packet_violation_warning:
3203
+ !id: 0x9c
3204
+ !bound: server
3205
+ violation_type: zigzag32 =>
3206
+ 0: malformed
3207
+ # Severity specifies the severity of the packet violation. The action the client takes after this
3208
+ # violation depends on the severity sent.
3209
+ severity: zigzag32 =>
3210
+ 0: warning
3211
+ 1: final_warning
3212
+ 2: terminating
3213
+ # PacketID is the ID of the invalid packet that was received.
3214
+ packet_id: zigzag32
3215
+ # ViolationContext holds a description on the violation of the packet.
3216
+ reason: string
3217
+
3218
+
3219
+ # MotionPredictionHints is sent by the server to the client. There is a predictive movement component for
3220
+ # entities. This packet fills the "history" of that component and entity movement is computed based on the
3221
+ # points. Vanilla sends this packet instead of the SetActorMotion packet when 'spatial optimisations' are
3222
+ # enabled.
3223
+ packet_motion_prediction_hints:
3224
+ !id: 0x9d
3225
+ !bound: client
3226
+ # EntityRuntimeID is the runtime ID of the entity whose velocity is sent to the client.
3227
+ entity_runtime_id: varint64
3228
+ # Velocity is the server-calculated velocity of the entity at the point of sending the packet.
3229
+ velocity: vec3f
3230
+ # OnGround specifies if the server currently thinks the entity is on the ground.
3231
+ on_ground: bool
3232
+
3233
+
3234
+ # AnimateEntity is sent by the server to animate an entity client-side. It may be used to play a single
3235
+ # animation, or to activate a controller which can start a sequence of animations based on different
3236
+ # conditions specified in an animation controller.
3237
+ # Much of the documentation of this packet can be found at
3238
+ # https://minecraft.gamepedia.com/Bedrock_Edition_beta_animation_documentation.
3239
+ packet_animate_entity:
3240
+ !id: 0x9e
3241
+ !bound: client
3242
+ # Animation is the name of a single animation to start playing.
3243
+ animation: string
3244
+ # NextState is the first state to start with. These states are declared in animation controllers (which,
3245
+ # in themselves, are animations too). These states in turn may have animations and transitions to move to
3246
+ # a next state.
3247
+ next_state: string
3248
+ # StopCondition is a MoLang expression that specifies when the animation should be stopped.
3249
+ stop_condition: string
3250
+ # StopConditionVersion is the MoLang stop condition version.
3251
+ stop_condition_version: li32
3252
+ # Controller is the animation controller that is used to manage animations. These controllers decide when
3253
+ # to play which animation.
3254
+ controller: string
3255
+ # How long to move from the previous animation to the next.
3256
+ blend_out_time: lf32
3257
+ # EntityRuntimeIDs is list of runtime IDs of entities that the animation should be applied to.
3258
+ runtime_entity_ids: varint64[]varint
3259
+
3260
+ # CameraShake is sent by the server to make the camera shake client-side. This feature was added for map-
3261
+ # making partners.
3262
+ packet_camera_shake:
3263
+ !id: 0x9f
3264
+ !bound: client
3265
+ # Intensity is the intensity of the shaking. The client limits this value to 4, so anything higher may
3266
+ # not work.
3267
+ intensity: lf32
3268
+ # Duration is the number of seconds the camera will shake for.
3269
+ duration: lf32
3270
+ # Type is the type of shake, and is one of the constants listed above. The different type affects how
3271
+ # the shake looks in game.
3272
+ type: u8
3273
+ # Action is the action to be performed, and is one of the constants listed above. Currently the
3274
+ # different actions will either add or stop shaking the client.
3275
+ action: u8 =>
3276
+ 0: add
3277
+ 1: stop
3278
+
3279
+ # PlayerFog is sent by the server to render the different fogs in the Stack. The types of fog are controlled
3280
+ # by resource packs to change how they are rendered, and the ability to create custom fog.
3281
+ packet_player_fog:
3282
+ !id: 0xa0
3283
+ !bound: client
3284
+ # Stack is a list of fog identifiers to be sent to the client. Examples of fog identifiers are
3285
+ # "minecraft:fog_ocean" and "minecraft:fog_hell".
3286
+ stack: string[]varint
3287
+
3288
+
3289
+ # CorrectPlayerMovePrediction is sent by the server if and only if StartGame.ServerAuthoritativeMovementMode
3290
+ # is set to AuthoritativeMovementModeServerWithRewind. The packet is used to correct movement at a specific
3291
+ # point in time.
3292
+ packet_correct_player_move_prediction:
3293
+ !id: 0xa1
3294
+ !bound: client
3295
+ # Position is the position that the player is supposed to be at at the tick written in the field below.
3296
+ # The client will change its current position based on movement after that tick starting from the
3297
+ # Position.
3298
+ position: vec3f
3299
+ # Delta is the change in position compared to what the client sent as its position at that specific tick.
3300
+ delta: vec3f
3301
+ # OnGround specifies if the player was on the ground at the time of the tick below.
3302
+ on_ground: bool
3303
+ # Tick is the tick of the movement which was corrected by this packet.
3304
+ tick: varint64
3305
+
3306
+ # ItemComponent is sent by the server to attach client-side components to a custom item.
3307
+ packet_item_component:
3308
+ !id: 0xa2
3309
+ !bound: client
3310
+ # `entries` holds a list of all custom items with their respective components set.
3311
+ entries: ItemComponentList
3312
+
3313
+ # FilterText is sent by the both the client and the server. The client sends the packet to the server to
3314
+ # allow the server to filter the text server-side. The server then responds with the same packet and the
3315
+ # safer version of the text.
3316
+ packet_filter_text_packet:
3317
+ !id: 0xa3
3318
+ !bound: client
3319
+ # Text is either the text from the client or the safer version of the text sent by the server.
3320
+ text: string
3321
+ # FromServer indicates if the packet was sent by the server or not.
3322
+ from_server: bool
3323
+
3324
+ # ClientBoundDebugRenderer is sent by the server to spawn an outlined cube on client-side.
3325
+ packet_debug_renderer:
3326
+ !id: 0xa4
3327
+ !bound: client
3328
+ # Type is the type of action. It is one of the constants above.
3329
+ type: li32 =>
3330
+ 1: clear
3331
+ 2: add_cube
3332
+ _: type ?
3333
+ if clear: void
3334
+ if add_cube:
3335
+ # Text is the text that is displayed above the debug.
3336
+ text: string
3337
+ # Position is the position to spawn the debug on.
3338
+ position: vec3f
3339
+ # Red is the red value from the RGBA colour rendered on the debug.
3340
+ red: lf32
3341
+ # Green is the green value from the RGBA colour rendered on the debug.
3342
+ green: lf32
3343
+ # Blue is the blue value from the RGBA colour rendered on the debug.
3344
+ blue: lf32
3345
+ # Alpha is the alpha value from the RGBA colour rendered on the debug.
3346
+ alpha: lf32
3347
+ # Duration is how long the debug will last in the world for. It is measured in milliseconds.
3348
+ duration: li64
3349
+
3350
+ # Sent by the server to synchronize/update entity properties as NBT, an alternative to Set Entity Data.
3351
+ packet_sync_entity_property:
3352
+ !id: 0xa5
3353
+ !bound: client
3354
+ nbt: nbt
3355
+
3356
+ # AddVolumeEntity sends a volume entity's definition and components from server to client.
3357
+ packet_add_volume_entity:
3358
+ !id: 0xa6
3359
+ !bound: client
3360
+ # EntityRuntimeID is the runtime ID of the entity. The runtime ID is unique for each world session, and
3361
+ # entities are generally identified in packets using this runtime ID.
3362
+ runtime_id: varint64
3363
+ # EntityMetadata is a map of entity metadata, which includes flags and data properties that alter in
3364
+ # particular the way the entity looks.
3365
+ nbt: nbt
3366
+ encoding_identifier: string
3367
+ instance_name: string
3368
+ bounds:
3369
+ min: BlockCoordinates
3370
+ max: BlockCoordinates
3371
+ dimension: zigzag32
3372
+ engine_version: string
3373
+
3374
+ # RemoveVolumeEntity indicates a volume entity to be removed from server to client.
3375
+ packet_remove_volume_entity:
3376
+ !id: 0xa7
3377
+ !bound: client
3378
+ # The Runtime Entity ID
3379
+ entity_id: varint64
3380
+
3381
+ # SimulationType is an in-progress packet. We currently do not know the use case.
3382
+ packet_simulation_type:
3383
+ !id: 0xa8
3384
+ # SimulationType is the simulation type selected
3385
+ type: u8 =>
3386
+ 0: game
3387
+ 1: editor
3388
+ 2: test
3389
+ 3: invalid
3390
+
3391
+ # NPCDialogue is a packet that allows the client to display dialog boxes for interacting with NPCs.
3392
+ packet_npc_dialogue:
3393
+ !id: 0xa9
3394
+ # ActorUniqueID is the ID of the NPC being requested.
3395
+ entity_id: lu64
3396
+ # ActionType is the type of action for the packet.
3397
+ action_type: varint =>
3398
+ 0: open
3399
+ 1: close
3400
+ # Dialogue is the text that the client should see.
3401
+ dialogue: string
3402
+ # SceneName is the scene the data was pulled from for the client.
3403
+ screen_name: string
3404
+ # NPCName is the name of the NPC to be displayed to the client.
3405
+ npc_name: string
3406
+ # ActionJSON is the JSON string of the buttons/actions the server can perform.
3407
+ action_json: string
3408
+
3409
+ packet_edu_uri_resource_packet:
3410
+ !id: 0xaa
3411
+ resource: EducationSharedResourceURI
3412
+
3413
+ # CreatePhoto is a packet that allows players to export photos from their portfolios into items in their inventory.
3414
+ # This packet only works on the Education Edition version of Minecraft.
3415
+ packet_create_photo:
3416
+ !id: 0xab
3417
+ # EntityUniqueID is the unique ID of the entity.
3418
+ entity_unique_id: li64
3419
+ # PhotoName is the name of the photo.
3420
+ photo_name: string
3421
+ # ItemName is the name of the photo as an item.
3422
+ item_name: string
3423
+
3424
+ # UpdateSubChunkBlocks is essentially just UpdateBlock packet, however for a set of blocks in a sub chunk.
3425
+ packet_update_subchunk_blocks:
3426
+ !id: 0xac
3427
+ # SubChunkX, SubChunkY, and SubChunkZ help identify the sub chunk.
3428
+ x: zigzag32
3429
+ y: zigzag32
3430
+ z: zigzag32
3431
+ # Blocks contains each updated block change entry.
3432
+ blocks: BlockUpdate[]varint
3433
+ # Extra contains each updated block change entry for the second layer, usually for waterlogged blocks.
3434
+ extra: BlockUpdate[]varint
3435
+
3436
+ packet_photo_info_request:
3437
+ !id: 0xad
3438
+ photo_id: zigzag64
3439
+
3440
+ SubChunkEntryWithoutCaching: []lu32
3441
+ dx: u8
3442
+ dy: u8
3443
+ dz: u8
3444
+ result: u8 =>
3445
+ 0: undefined
3446
+ 1: success
3447
+ 2: chunk_not_found
3448
+ 3: invalid_dimension
3449
+ 4: player_not_found
3450
+ 5: y_index_out_of_bounds
3451
+ 6: success_all_air
3452
+ # Payload has the terrain data, if the chunk isn't empty and caching is disabled
3453
+ payload: ByteArray
3454
+ heightmap_type: u8 =>
3455
+ 0: no_data
3456
+ 1: has_data
3457
+ 2: too_high
3458
+ 3: too_low
3459
+ heightmap: heightmap_type ?
3460
+ if has_data: '["buffer", { "count": 256 }]'
3461
+
3462
+ SubChunkEntryWithCaching: []lu32
3463
+ dx: u8
3464
+ dy: u8
3465
+ dz: u8
3466
+ result: u8 =>
3467
+ 0: undefined
3468
+ 1: success
3469
+ 2: chunk_not_found
3470
+ 3: invalid_dimension
3471
+ 4: player_not_found
3472
+ 5: y_index_out_of_bounds
3473
+ 6: success_all_air
3474
+ # Payload has the terrain data, if the chunk isn't empty and caching is disabled
3475
+ payload: result ?
3476
+ if success_all_air: void
3477
+ default: ByteArray
3478
+ heightmap_type: u8 =>
3479
+ 0: no_data
3480
+ 1: has_data
3481
+ 2: too_high
3482
+ 3: too_low
3483
+ heightmap: heightmap_type ?
3484
+ if has_data: '["buffer", { "count": 256 }]'
3485
+ blob_id: lu64
3486
+
3487
+ # SubChunk sends data about multiple sub-chunks around a center point.
3488
+ packet_subchunk:
3489
+ !id: 0xae
3490
+ !bound: client
3491
+ cache_enabled: bool
3492
+ dimension: zigzag32
3493
+ # Origin point
3494
+ origin: vec3i
3495
+ entries: cache_enabled ?
3496
+ if true: SubChunkEntryWithCaching
3497
+ if false: SubChunkEntryWithoutCaching
3498
+
3499
+ packet_subchunk_request:
3500
+ !id: 0xaf
3501
+ !bound: server
3502
+ dimension: zigzag32
3503
+ # Origin point
3504
+ origin: vec3i
3505
+ requests: []lu32
3506
+ dx: u8
3507
+ dy: u8
3508
+ dz: u8
3509
+
3510
+ # ClientStartItemCooldown is sent by the client to the server to initiate a cooldown on an item. The purpose of this
3511
+ # packet isn't entirely clear.
3512
+ packet_client_start_item_cooldown:
3513
+ !id: 0xb0
3514
+ !bound: server
3515
+ category: string
3516
+ # Duration is the duration of ticks the cooldown should last.
3517
+ duration: zigzag32
3518
+
3519
+ # ScriptMessage is used to communicate custom messages from the client to the server, or from the server to the client.
3520
+ # While the name may suggest this packet is used for the discontinued scripting API, it is likely instead for the
3521
+ # GameTest framework.
3522
+ packet_script_message:
3523
+ !id: 0xb1
3524
+ !bound: server
3525
+ # Message ID is the identifier of the message, used by either party to identify the message data sent.
3526
+ message_id: string
3527
+ # Data contains the data of the message.
3528
+ data: string
3529
+
3530
+ # CodeBuilderSource is an Education Edition packet sent by the client to the server to run an operation with a
3531
+ packet_code_builder_source:
3532
+ !id: 0xb2
3533
+ !bound: client
3534
+ # Operation is used to distinguish the operation performed. It is always one of the constants listed above.
3535
+ operation: u8 =>
3536
+ - none
3537
+ - get
3538
+ - set
3539
+ - reset
3540
+ # Category is used to distinguish the category of the operation performed. It is always one of the constants
3541
+ category: u8 =>
3542
+ - none
3543
+ - code_status
3544
+ - instantiation
3545
+ # Value contains extra data about the operation performed. It is always empty unless the operation is
3546
+ value: string
3547
+
3548
+ # TickingAreasLoadStatus is sent by the server to the client to notify the client of a ticking area's loading status.
3549
+ packet_ticking_areas_load_status:
3550
+ !id: 0xb3
3551
+ !bound: client
3552
+ # Preload is true if the server is waiting for the area's preload.
3553
+ preload: bool
3554
+
3555
+ # DimensionData is a packet sent from the server to the client containing information about data-driven dimensions
3556
+ # that the server may have registered. This packet does not seem to be sent by default, rather only being sent when
3557
+ # any data-driven dimensions are registered.
3558
+ packet_dimension_data:
3559
+ !id: 0xb4
3560
+ !bound: client
3561
+ definitions: []varint
3562
+ id: string
3563
+ max_height: zigzag32
3564
+ min_height: zigzag32
3565
+ generator: zigzag32 =>
3566
+ 0: legacy
3567
+ 1: overworld
3568
+ 2: flat
3569
+ 3: nether
3570
+ 4: end
3571
+ 5: void
3572
+
3573
+ # AgentAction is an Education Edition packet sent from the server to the client to return a response to a
3574
+ # previously requested action.
3575
+ packet_agent_action:
3576
+ !id: 0xb5
3577
+ !bound: client
3578
+ request_id: string
3579
+ action_type: zigzag32 =>
3580
+ - none
3581
+ - attack
3582
+ - collect
3583
+ - destroy
3584
+ - detect_redstone
3585
+ - detect_obstacle
3586
+ - drop
3587
+ - drop_all
3588
+ - inspect
3589
+ - inspect_data
3590
+ - inspect_item_count
3591
+ - inspect_item_detail
3592
+ - inspect_item_space
3593
+ - interact
3594
+ - move
3595
+ - place_block
3596
+ - till
3597
+ - transfer_item_to
3598
+ - turn
3599
+ body: string
3600
+
3601
+ # ChangeMobProperty is a packet sent from the server to the client to change one of the properties of a mob client-side.
3602
+ packet_change_mob_property:
3603
+ !id: 0xb6
3604
+ !bound: client
3605
+ # EntityUniqueID is the unique ID of the entity whose property is being changed.
3606
+ entity_unique_id: zigzag64
3607
+ # Property is the name of the property being updated.
3608
+ property: string
3609
+ # BoolValue is set if the property value is a bool type. If the type is not a bool, this field is ignored.
3610
+ bool_value: bool
3611
+ # StringValue is set if the property value is a string type. If the type is not a string, this field is ignored.
3612
+ string_value: string
3613
+ # IntValue is set if the property value is an int type. If the type is not an int, this field is ignored.
3614
+ int_value: zigzag32
3615
+ # FloatValue is set if the property value is a float type. If the type is not a float, this field is ignored.
3616
+ float_value: lf32
3617
+
3618
+ # LessonProgress is a packet sent by the server to the client to inform the client of updated progress on a lesson.
3619
+ # This packet only functions on the Minecraft: Education Edition version of the game.
3620
+ packet_lesson_progress:
3621
+ !id: 0xb7
3622
+ # Action is the action the client should perform to show progress. This is one of the constants defined above.
3623
+ action: u8
3624
+ # Score is the score the client should use when displaying the progress.
3625
+ score: zigzag32
3626
+ # Identifier is the identifier of the lesson that is being progressed.
3627
+ identifier: string
3628
+
3629
+ # RequestAbility is a packet sent by the client to the server to request permission for a specific ability from the
3630
+ # server.
3631
+ packet_request_ability:
3632
+ !id: 0xb8
3633
+ !bound: server
3634
+ # Ability is the ability that the client is requesting. This is one of the constants defined above.
3635
+ ability: zigzag32 =>
3636
+ - build
3637
+ - mine
3638
+ - doors_and_switches
3639
+ - open_containers
3640
+ - attack_players
3641
+ - attack_mobs
3642
+ - operator_commands
3643
+ - teleport
3644
+ - invulnerable
3645
+ - flying
3646
+ - may_fly
3647
+ - instant_build
3648
+ - lightning
3649
+ - fly_speed
3650
+ - walk_speed
3651
+ - muted
3652
+ - world_builder
3653
+ - no_clip
3654
+ - ability_count
3655
+ # Value type decides which of the fields you should read/write from
3656
+ value_type: u8 =>
3657
+ 1: bool
3658
+ 2: float
3659
+ # If value type is bool, use this value
3660
+ bool_value: bool
3661
+ # If value type is float, use this value
3662
+ float_val: lf32
3663
+
3664
+ # RequestPermissions is a packet sent from the client to the server to request permissions that the client does not
3665
+ # currently have. It can only be sent by operators and host in vanilla Minecraft.
3666
+ packet_request_permissions:
3667
+ !id: 0xb9
3668
+ !bound: server
3669
+ # EntityUniqueID is the unique ID of the player. The unique ID is unique for the entire world and is
3670
+ # often used in packets. Most servers send an EntityUniqueID equal to the EntityRuntimeID.
3671
+ entity_unique_id: li64
3672
+ # PermissionLevel is the current permission level of the player. Same as constants in AdventureSettings packet.
3673
+ permission_level: PermissionLevel
3674
+ # RequestedPermissions contains the requested permission flags.
3675
+ requested_permissions: RequestPermissions
3676
+
3677
+ RequestPermissions: [ "bitflags",
3678
+ {
3679
+ "type": "lu16",
3680
+ "flags": {
3681
+ "build": 0b1,
3682
+ "mine": 0b10,
3683
+ "doors_and_switches": 0b100,
3684
+ "open_containers": 0b1000,
3685
+ "attack_players": 0b10000,
3686
+ "attack_mobs": 0b100000,
3687
+ "operator": 0b1000000,
3688
+ "teleport": 0b10000000
3689
+ }
3690
+ }
3691
+ ]
3692
+
3693
+ # ToastRequest is a packet sent from the server to the client to display a toast to the top of the screen. These toasts
3694
+ # are the same as the ones seen when, for example, loading a new resource pack or obtaining an achievement.
3695
+ packet_toast_request:
3696
+ !id: 0xba
3697
+ !bound: client
3698
+ # Title is the title of the toast.
3699
+ title: string
3700
+ # Message is the message that the toast may contain alongside the title.
3701
+ message: string
3702
+
3703
+ # UpdateAbilities is a packet sent from the server to the client to update the abilities of the player. It, along with
3704
+ # the UpdateAdventureSettings packet, are replacements of the AdventureSettings packet since v1.19.10.
3705
+ packet_update_abilities:
3706
+ !id: 0xbb
3707
+ !bound: client
3708
+ # EntityUniqueID is the unique ID of the player. The unique ID is a value that remains consistent across
3709
+ # different sessions of the same world, but most servers simply fill the runtime ID of the entity out for
3710
+ # this field.
3711
+ entity_unique_id: li64
3712
+ # PlayerPermissions is the permission level of the player. It is a value from 0-3, with 0 being visitor,
3713
+ # 1 being member, 2 being operator and 3 being custom.
3714
+ permission_level: PermissionLevel
3715
+ # CommandPermissions is a permission level that specifies the kind of commands that the player is
3716
+ # allowed to use. It is one of the CommandPermissionLevel constants in the AdventureSettings packet.
3717
+ command_permission: CommandPermissionLevel
3718
+ # Layers contains all ability layers and their potential values. This should at least have one entry, being the
3719
+ # base layer.
3720
+ abilities: AbilityLayers[]u8
3721
+
3722
+ # UpdateAdventureSettings is a packet sent from the server to the client to update the adventure settings of the player.
3723
+ # It, along with the UpdateAbilities packet, are replacements of the AdventureSettings packet since v1.19.10.
3724
+ packet_update_adventure_settings:
3725
+ !id: 0xbc
3726
+ !bound: client
3727
+ # NoPvM is a boolean indicating whether the player is allowed to fight mobs or not.
3728
+ no_pvm: bool
3729
+ # NoMvP is a boolean indicating whether mobs are allowed to fight the player or not. It is unclear why this is sent
3730
+ # to the client.
3731
+ no_mvp: bool
3732
+ # ImmutableWorld is a boolean indicating whether the player is allowed to modify the world or not.
3733
+ immutable_world: bool
3734
+ # ShowNameTags is a boolean indicating whether player name tags are shown or not.
3735
+ show_name_tags: bool
3736
+ # AutoJump is a boolean indicating whether the player is allowed to jump automatically or not.
3737
+ auto_jump: bool
3738
+
3739
+ # DeathInfo is a packet sent from the server to the client expected to be sent when a player dies. It contains messages
3740
+ # related to the player's death, which are shown on the death screen as of v1.19.10.
3741
+ packet_death_info:
3742
+ !id: 0xbd
3743
+ !bound: client
3744
+ # Cause is the cause of the player's death, such as "suffocation" or "suicide".
3745
+ cause: string
3746
+ # Messages is a list of death messages to be shown on the death screen.
3747
+ messages: string[]varint
3748
+
3749
+ # EditorNetwork is a packet sent from the server to the client and vise-versa to communicate editor-mode related
3750
+ # information. It carries a single compound tag containing the relevant information.
3751
+ packet_editor_network:
3752
+ !id: 0xbe
3753
+ !bound: client
3754
+ # Payload is a network little endian compound tag holding data relevant to the editor.
3755
+ payload: nbt
3756
+
3757
+ # FeatureRegistry is a packet used to notify the client about the world generation features the server is currently
3758
+ # using. This is used in combination with the client-side world generation system introduced in v1.19.20, allowing the
3759
+ # client to completely generate the chunks of the world without having to rely on the server.
3760
+ packet_feature_registry:
3761
+ !id: 0xbf
3762
+ !bound: client
3763
+ # Features is a slice of all registered world generation features.
3764
+ features: []varint
3765
+ name: string
3766
+ options: string
3767
+
3768
+ # ServerStats is a packet sent from the server to the client to update the client on server statistics. It is purely
3769
+ # used for telemetry.
3770
+ packet_server_stats:
3771
+ !id: 0xc0
3772
+ !bound: client
3773
+ server_time: lf32
3774
+ network_time: lf32
3775
+
3776
+ packet_request_network_settings:
3777
+ !id: 0xc1
3778
+ !bound: server
3779
+ client_protocol: i32
3780
+
3781
+ packet_game_test_request:
3782
+ !id: 0xc2
3783
+ # MaxTestsPerBatch ...
3784
+ max_tests_per_batch: varint
3785
+ # Repetitions represents the amount of times the test will be run.
3786
+ repetitions: varint
3787
+ # Rotation represents the rotation of the test. It is one of the constants above.
3788
+ rotation: u8 =>
3789
+ - 0deg
3790
+ - 90deg
3791
+ - 180deg
3792
+ - 270deg
3793
+ - 360deg
3794
+ # StopOnError indicates whether the test should immediately stop when an error is encountered.
3795
+ stop_on_error: bool
3796
+ # Position is the position at which the test will be performed.
3797
+ position: BlockCoordinates
3798
+ # TestsPerRow ...
3799
+ tests_per_row: varint
3800
+ # Name represents the name of the test.
3801
+ name: string
3802
+
3803
+ # GameTestResults is a packet sent in response to the GameTestRequest packet, with a boolean indicating whether the
3804
+ # test was successful or not, and an error string if the test failed.
3805
+ packet_game_test_results:
3806
+ !id: 0xc3
3807
+ # Succeeded indicates whether the test succeeded or not.
3808
+ succeeded: bool
3809
+ # Error is the error that occurred. If Succeeded is true, this field is empty.
3810
+ error: string
3811
+ # Name represents the name of the test.
3812
+ name: string
3813
+
3814
+ InputLockFlags: [ "bitflags", {
3815
+ "type": "varint",
3816
+ "flags": {
3817
+ "move": 0x02,
3818
+ "jump": 0x04,
3819
+ "sneak": 0x08,
3820
+ "mount": 0x10,
3821
+ "dismount": 0x20,
3822
+ "rotation": 0x40
3823
+ }
3824
+ } ]
3825
+
3826
+ packet_update_client_input_locks:
3827
+ !id: 0xc4
3828
+ !bound: client
3829
+ # Locks is an encoded bitset of all locks that are currently active. The locks are defined in the constants above.
3830
+ locks: InputLockFlags
3831
+ # Position is the server's position of the client at the time the packet was sent. It is unclear what the exact
3832
+ # purpose of this field is.
3833
+ position: vec3f
3834
+
3835
+ packet_client_cheat_ability:
3836
+ !id: 0xc5
3837
+ !bound: client
3838
+ # EntityUniqueID is the unique ID of the player. The unique ID is a value that remains consistent across
3839
+ # different sessions of the same world, but most servers simply fill the runtime ID of the entity out for
3840
+ # this field.
3841
+ entity_unique_id: li64
3842
+ # PlayerPermissions is the permission level of the player. It is a value from 0-3, with 0 being visitor,
3843
+ # 1 being member, 2 being operator and 3 being custom.
3844
+ permission_level: PermissionLevel
3845
+ # CommandPermissions is a permission level that specifies the kind of commands that the player is
3846
+ # allowed to use. It is one of the CommandPermissionLevel constants in the AdventureSettings packet.
3847
+ command_permission: CommandPermissionLevel
3848
+ # Layers contains all ability layers and their potential values. This should at least have one entry, being the
3849
+ # base layer.
3850
+ abilities: AbilityLayers[]u8