minecraft-data 2.93.1 → 2.97.0

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