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