Difference between revisions of "Pre-release protocol"

From wiki.vg
Jump to navigation Jump to search
(→‎Entity Metadata: Added changes on entity metadata)
(23w13a)
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
This page documents the changes from the [[Protocol|last stable Minecraft release]] (currently [[Protocol version numbers|1.19.3, protocol 761]]) to the current pre-release (currently [[Protocol version numbers|1.19.4-pre3, protocol {{Snapshot PVN|1073741946}}]]). Note that this page contains bleeding-edge information that may not be completely or correctly documented.
+
This page documents the changes from the [[Protocol|last stable Minecraft release]] (currently [[Protocol version numbers|1.19.4, protocol 762]]) to the current pre-release (currently [[Protocol version numbers|23w13a, protocol {{Snapshot PVN|1073741952}}]]). Note that this page contains bleeding-edge information that may not be completely or correctly documented.
  
 
One who wishes to commandeer the merging of this into [[Protocol]] when an update is made must be sure to respect any changes that may have occurred to the respective packets there.
 
One who wishes to commandeer the merging of this into [[Protocol]] when an update is made must be sure to respect any changes that may have occurred to the respective packets there.
Line 12: Line 12:
  
 
=== Packets ===
 
=== Packets ===
 +
 
{| class="wikitable"
 
{| class="wikitable"
 
  ! ID
 
  ! ID
Line 18: Line 19:
 
  |-
 
  |-
 
!colspan="4"| Play clientbound
 
!colspan="4"| Play clientbound
{{PacketList|0x00|Bundle Delimiter|rel=added}}
+
{{PacketList|0x31|Open Sign Editor}}
{{PacketList|{{change|0x00|0x01}}|Spawn Entity|pre=unchanged}}
+
{{PacketList|0x6B|Feature Flags}}
{{PacketList|{{change|0x01|0x02}}|Spawn Experience Orb|pre=unchanged}}
+
{{PacketList|0x6D|Update Recipes}}
{{PacketList|{{change|0x02|0x03}}|Spawn Player|pre=unchanged}}
 
{{PacketList|{{change|0x03|0x04}}|Entity Animation|pre=unchanged}}
 
{{PacketList|{{change|0x04|0x05}}|Award Statistics|pre=unchanged}}
 
{{PacketList|{{change|0x05|0x06}}|Acknowledge Block Change|pre=unchanged}}
 
{{PacketList|{{change|0x06|0x07}}|Set Block Destroy Stage|pre=unchanged}}
 
{{PacketList|{{change|0x07|0x08}}|Block Entity Data|pre=unchanged}}
 
{{PacketList|{{change|0x08|0x09}}|Block Action|pre=unchanged}}
 
{{PacketList|{{change|0x09|0x0A}}|Block Update|pre=unchanged}}
 
{{PacketList|{{change|0x0A|0x0B}}|Boss Bar|pre=unchanged}}
 
{{PacketList|{{change|0x0B|0x0C}}|Change Difficulty|pre=unchanged}}
 
{{PacketList|0x0D|Chunk Biomes|rel=added}}
 
{{PacketList|{{change|0x0C|0x0E}}|Clear Titles|pre=unchanged}}
 
{{PacketList|{{change|0x0D|0x0F}}|Command Suggestions Response|pre=unchanged}}
 
{{PacketList|{{change|0x0E|0x10}}|Commands|pre=unchanged}}
 
{{PacketList|{{change|0x0F|0x11}}|Close Container|pre=unchanged}}
 
{{PacketList|{{change|0x10|0x12}}|Set Container Content|pre=unchanged}}
 
{{PacketList|{{change|0x11|0x13}}|Set Container Property|pre=unchanged}}
 
{{PacketList|{{change|0x12|0x14}}|Set Container Slot|pre=unchanged}}
 
{{PacketList|{{change|0x13|0x15}}|Set Cooldown|pre=unchanged}}
 
{{PacketList|{{change|0x14|0x16}}|Chat Suggestions|pre=unchanged}}
 
{{PacketList|{{change|0x15|0x17}}|Plugin Message|pre=unchanged}}
 
{{PacketList|0x18|Damage Event|rel=added}}
 
{{PacketList|{{change|0x16|0x19}}|Delete Message|pre=unchanged}}
 
{{PacketList|{{change|0x17|0x1A}}|Disconnect (play)|pre=unchanged}}
 
{{PacketList|{{change|0x18|0x1B}}|Disguised Chat Message|pre=unchanged}}
 
{{PacketList|{{change|0x19|0x1C}}|Entity Event|pre=unchanged}}
 
{{PacketList|{{change|0x1A|0x1D}}|Explosion|pre=unchanged}}
 
{{PacketList|{{change|0x1B|0x1E}}|Unload Chunk|pre=unchanged}}
 
{{PacketList|{{change|0x1C|0x1F}}|Game Event|pre=unchanged}}
 
{{PacketList|{{change|0x1D|0x20}}|Open Horse Screen|pre=unchanged}}
 
{{PacketList|0x21|Hurt Animation|rel=added}}
 
{{PacketList|{{change|0x1E|0x22}}|Initialize World Border|pre=unchanged}}
 
{{PacketList|{{change|0x1F|0x23}}|Keep Alive|pre=unchanged}}
 
{{PacketList|{{change|0x20|0x24}}|Chunk Data and Update Light|pre=unchanged}}
 
{{PacketList|{{change|0x21|0x25}}|World Event|pre=unchanged}}
 
{{PacketList|{{change|0x22|0x26}}|Particle|pre=unchanged}}
 
{{PacketList|{{change|0x23|0x27}}|Update Light|pre=unchanged}}
 
{{PacketList|{{change|0x24|0x28}}|Login (play)|pre=unchanged}}
 
{{PacketList|{{change|0x25|0x29}}|Map Data|pre=unchanged}}
 
{{PacketList|{{change|0x26|0x2A}}|Merchant Offers|pre=unchanged}}
 
{{PacketList|{{change|0x27|0x2B}}|Update Entity Position|pre=unchanged}}
 
{{PacketList|{{change|0x28|0x2C}}|Update Entity Position and Rotation|pre=unchanged}}
 
{{PacketList|{{change|0x29|0x2D}}|Update Entity Rotation|pre=unchanged}}
 
{{PacketList|{{change|0x2A|0x2E}}|Move Vehicle|pre=unchanged}}
 
{{PacketList|{{change|0x2B|0x2F}}|Open Book|pre=unchanged}}
 
{{PacketList|{{change|0x2C|0x30}}|Open Screen|pre=unchanged}}
 
{{PacketList|{{change|0x2D|0x31}}|Open Sign Editor|pre=unchanged}}
 
{{PacketList|{{change|0x2E|0x32}}|Ping (play)|pre=unchanged}}
 
{{PacketList|{{change|0x2F|0x33}}|Place Ghost Recipe|pre=unchanged}}
 
{{PacketList|{{change|0x30|0x34}}|Player Abilities|pre=unchanged}}
 
{{PacketList|{{change|0x31|0x35}}|Player Chat Message|pre=unchanged}}
 
{{PacketList|{{change|0x32|0x36}}|End Combat|pre=unchanged}}
 
{{PacketList|{{change|0x33|0x37}}|Enter Combat|pre=unchanged}}
 
{{PacketList|{{change|0x34|0x38}}|Combat Death|pre=unchanged}}
 
{{PacketList|{{change|0x35|0x39}}|Player Info Remove|pre=unchanged}}
 
{{PacketList|{{change|0x36|0x3A}}|Player Info Update|pre=unchanged}}
 
{{PacketList|{{change|0x37|0x3B}}|Look At|pre=unchanged}}
 
{{PacketList|{{change|0x38|0x3C}}|Synchronize Player Position}}
 
{{PacketList|{{change|0x39|0x3D}}|Update Recipe Book|pre=unchanged}}
 
{{PacketList|{{change|0x3A|0x3E}}|Remove Entities|pre=unchanged}}
 
{{PacketList|{{change|0x3B|0x3F}}|Remove Entity Effect|pre=unchanged}}
 
{{PacketList|{{change|0x3C|0x40}}|Resource Pack|pre=unchanged}}
 
{{PacketList|{{change|0x3D|0x41}}|Respawn|pre=unchanged}}
 
{{PacketList|{{change|0x3E|0x42}}|Set Head Rotation|pre=unchanged}}
 
{{PacketList|{{change|0x3F|0x43}}|Update Section Blocks|pre=unchanged}}
 
{{PacketList|{{change|0x40|0x44}}|Select Advancements Tab|pre=unchanged}}
 
{{PacketList|{{change|0x41|0x45}}|Server Data}}
 
{{PacketList|{{change|0x42|0x46}}|Set Action Bar Text|pre=unchanged}}
 
{{PacketList|{{change|0x43|0x47}}|Set Border Center|pre=unchanged}}
 
{{PacketList|{{change|0x44|0x48}}|Set Border Lerp Size|pre=unchanged}}
 
{{PacketList|{{change|0x45|0x49}}|Set Border Size|pre=unchanged}}
 
{{PacketList|{{change|0x46|0x4A}}|Set Border Warning Delay|pre=unchanged}}
 
{{PacketList|{{change|0x47|0x4B}}|Set Border Warning Distance|pre=unchanged}}
 
{{PacketList|{{change|0x48|0x4C}}|Set Camera|pre=unchanged}}
 
{{PacketList|{{change|0x49|0x4D}}|Set Held Item|pre=unchanged}}
 
{{PacketList|{{change|0x4A|0x4E}}|Set Center Chunk|pre=unchanged}}
 
{{PacketList|{{change|0x4B|0x4F}}|Set Render Distance|pre=unchanged}}
 
{{PacketList|{{change|0x4C|0x50}}|Set Default Spawn Position|pre=unchanged}}
 
{{PacketList|{{change|0x4D|0x51}}|Display Objective|pre=unchanged}}
 
{{PacketList|{{change|0x4E|0x52}}|Set Entity Metadata|pre=unchanged}}
 
{{PacketList|{{change|0x4F|0x53}}|Link Entities|pre=unchanged}}
 
{{PacketList|{{change|0x50|0x54}}|Set Entity Velocity|pre=unchanged}}
 
{{PacketList|{{change|0x51|0x55}}|Set Equipment|pre=unchanged}}
 
{{PacketList|{{change|0x52|0x56}}|Set Experience|pre=unchanged}}
 
{{PacketList|{{change|0x53|0x57}}|Set Health|pre=unchanged}}
 
{{PacketList|{{change|0x54|0x58}}|Update Objectives|pre=unchanged}}
 
{{PacketList|{{change|0x55|0x59}}|Set Passengers|pre=unchanged}}
 
{{PacketList|{{change|0x56|0x5A}}|Update Teams|pre=unchanged}}
 
{{PacketList|{{change|0x57|0x5B}}|Update Score|pre=unchanged}}
 
{{PacketList|{{change|0x58|0x5C}}|Set Simulation Distance|pre=unchanged}}
 
{{PacketList|{{change|0x59|0x5D}}|Set Subtitle Text|pre=unchanged}}
 
{{PacketList|{{change|0x5A|0x5E}}|Update Time|pre=unchanged}}
 
{{PacketList|{{change|0x5B|0x5F}}|Set Title Text|pre=unchanged}}
 
{{PacketList|{{change|0x5C|0x60}}|Set Title Animation Times|pre=unchanged}}
 
{{PacketList|{{change|0x5D|0x61}}|Entity Sound Effect|pre=unchanged}}
 
{{PacketList|{{change|0x5E|0x62}}|Sound Effect|pre=unchanged}}
 
{{PacketList|{{change|0x5F|0x63}}|Stop Sound|pre=unchanged}}
 
{{PacketList|{{change|0x60|0x64}}|System Chat Message|pre=unchanged}}
 
{{PacketList|{{change|0x61|0x65}}|Set Tab List Header And Footer|pre=unchanged}}
 
{{PacketList|{{change|0x62|0x66}}|Tag Query Response|pre=unchanged}}
 
{{PacketList|{{change|0x63|0x67}}|Pickup Item|pre=unchanged}}
 
{{PacketList|{{change|0x64|0x68}}|Teleport Entity|pre=unchanged}}
 
{{PacketList|{{change|0x65|0x69}}|Update Advancements|pre=unchanged}}
 
{{PacketList|{{change|0x66|0x6A}}|Update Attributes|pre=unchanged}}
 
{{PacketList|{{change|0x67|0x6B}}|Feature Flags|pre=unchanged}}
 
{{PacketList|{{change|0x68|0x6C}}|Entity Effect|pre=unchanged}}
 
{{PacketList|{{change|0x69|0x6D}}|Update Recipes}}
 
{{PacketList|{{change|0x6A|0x6E}}|Update Tags|pre=unchanged}}
 
 
|-
 
|-
 
!colspan="4"| Play serverbound
 
!colspan="4"| Play serverbound
{{PacketList|{{change|0x20|0x06}}|Player Session|pre=unchanged}}
+
{{PacketList|0x2E|Update Sign}}
{{PacketList|{{change|0x06|0x07}}|Client Command|pre=unchanged}}
 
{{PacketList|{{change|0x07|0x08}}|Client Information|pre=unchanged}}
 
{{PacketList|{{change|0x08|0x09}}|Command Suggestions Request|pre=unchanged}}
 
{{PacketList|{{change|0x09|0x0A}}|Click Container Button|pre=unchanged}}
 
{{PacketList|{{change|0x0A|0x0B}}|Click Container|pre=unchanged}}
 
{{PacketList|{{change|0x0B|0x0C}}|Close Container|pre=unchanged}}
 
{{PacketList|{{change|0x0C|0x0D}}|Plugin Message|pre=unchanged}}
 
{{PacketList|{{change|0x0D|0x0E}}|Edit Book|pre=unchanged}}
 
{{PacketList|{{change|0x0E|0x0F}}|Query Entity Tag|pre=unchanged}}
 
{{PacketList|{{change|0x0F|0x10}}|Interact|pre=unchanged}}
 
{{PacketList|{{change|0x10|0x11}}|Jigsaw Generate|pre=unchanged}}
 
{{PacketList|{{change|0x11|0x12}}|Keep Alive|pre=unchanged}}
 
{{PacketList|{{change|0x12|0x13}}|Lock Difficulty|pre=unchanged}}
 
{{PacketList|{{change|0x13|0x14}}|Set Player Position|pre=unchanged}}
 
{{PacketList|{{change|0x14|0x15}}|Set Player Position and Rotation|pre=unchanged}}
 
{{PacketList|{{change|0x15|0x16}}|Set Player Rotation|pre=unchanged}}
 
{{PacketList|{{change|0x16|0x17}}|Set Player On Ground|pre=unchanged}}
 
{{PacketList|{{change|0x17|0x18}}|Move Vehicle|pre=unchanged}}
 
{{PacketList|{{change|0x18|0x19}}|Paddle Boat|pre=unchanged}}
 
{{PacketList|{{change|0x19|0x1A}}|Pick Item|pre=unchanged}}
 
{{PacketList|{{change|0x1A|0x1B}}|Place Recipe|pre=unchanged}}
 
{{PacketList|{{change|0x1B|0x1C}}|Player Abilities|pre=unchanged}}
 
{{PacketList|{{change|0x1C|0x1D}}|Player Action|pre=unchanged}}
 
{{PacketList|{{change|0x1D|0x1E}}|Player Command|pre=unchanged}}
 
{{PacketList|{{change|0x1E|0x1F}}|Player Input|pre=unchanged}}
 
{{PacketList|{{change|0x1F|0x20}}|Pong (play)|pre=unchanged}}
 
 
|}
 
|}
  
Line 166: Line 33:
 
== Entity Metadata ==
 
== Entity Metadata ==
  
=== Entity Metadata Format ===
+
No changes so far.
  
{| class="wikitable"
+
=== Entity ===
! Value of Type field
 
! [[Data types|Type]] of Value field
 
! Notes
 
|-
 
| 0
 
| Byte
 
|
 
|-
 
| 1
 
| VarInt
 
|
 
|-
 
| 2
 
| VarLong
 
|
 
|-
 
| 3
 
| Float
 
|
 
|-
 
| 4
 
| String
 
|
 
|-
 
| 5
 
| [[Chat]]
 
|
 
|-
 
| 6
 
| OptChat (Boolean + Optional [[Chat]])
 
| [[Chat]] is present if the Boolean is set to true
 
|-
 
| 7
 
| [[Slot]]
 
|
 
|-
 
| 8
 
| Boolean
 
|
 
|-
 
| 9
 
| Rotation
 
| 3 floats: rotation on x, rotation on y, rotation on z
 
|-
 
| 10
 
| [[Data Types#Position|Position]]
 
|
 
|-
 
| 11
 
| OptPosition (Boolean + Optional Position)
 
| Position is present if the Boolean is set to true
 
|-
 
| 12
 
| Direction (VarInt)
 
| (Down = 0, Up = 1, North = 2, South = 3, West = 4, East = 5)
 
|-
 
| 13
 
| OptUUID (Boolean + Optional UUID)
 
| UUID is present if the Boolean is set to true
 
|- {{added}}
 
| 14
 
| BlockID (VarInt)
 
|
 
|-
 
| {{change|14|15}}
 
| OptBlockID (VarInt)
 
| 0 for absent (implies air); otherwise, a block state ID as per the global palette
 
|-
 
| {{change|15|16}}
 
| [[NBT]]
 
|
 
|-
 
| {{change|16|17}}
 
| [[Data Types#Particle|Particle]]
 
|
 
|-
 
| {{change|17|18}}
 
| Villager Data
 
| 3 VarInts: villager type, villager profession, level
 
|-
 
| {{change|18|19}}
 
| OptVarInt
 
| 0 for absent; 1 + actual value otherwise.  Used for entity IDs.
 
|-
 
| {{change|19|20}}
 
| Pose
 
| A VarInt enum: 0: STANDING, 1: FALL_FLYING, 2: SLEEPING, 3: SWIMMING, 4: SPIN_ATTACK, 5: SNEAKING, 6: LONG_JUMPING, 7: DYING, 8: CROAKING, 9: USING_TONGUE, 10: SITTING, 11: ROARING, 12: SNIFFING, 13: EMERGING, 14: DIGGING
 
|-
 
| {{change|20|21}}
 
| Cat Variant
 
| A VarInt that points towards the CAT_VARIANT registry.
 
|-
 
| {{change|21|22}}
 
| Frog Variant
 
| A VarInt that points towards the FROG_VARIANT registry.
 
|-
 
| {{change|22|23}}
 
| OptGlobalPos (Boolean + Optional GlobalPos)
 
| A dimension identifier and [[Data Types#Position|Position]].
 
|-
 
| {{change|23|24}}
 
| Painting Variant
 
| A VarInt that points towards the PAINTING_VARIANT registry.
 
|- {{added}}
 
| 25
 
| Sniffer State
 
| A VarInt enum: IDLING = 0, FEELING_HAPPY = 1, SCENTING = 2, SNIFFING = 3, SEARCHING = 4, DIGGING = 5, RISING = 6
 
|
 
|- {{added}}
 
| 26
 
| Vector3
 
| 3 floats: x, y, z
 
|
 
|- {{added}}
 
| 27
 
| Quaternion
 
| 4 floats: x, y, z, w
 
|
 
|}
 
  
=== Abstract Horse ===
+
No changes so far.
 
 
{{Metadata inherit|Abstract Horse|inherits=Animal|start_at=17}}
 
 
 
{{warning|The removal of the Owner field shifts up the field indexes of all classes that inherit this one. These changes are not recorded here.}}
 
 
 
{| class="wikitable"
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
|rowspan="9"| {{Metadata id|}}
 
|rowspan="9"| Byte
 
! Bit mask
 
! Meaning
 
|rowspan="9"| 0
 
|-
 
| 0x01
 
| ''Unused''
 
|-
 
| 0x02
 
| Is Tame
 
|-
 
| 0x04
 
| Is saddled
 
|-
 
| 0x08
 
| Has bred
 
|-
 
| 0x10
 
| Is eating
 
|-
 
| 0x20
 
| Is rearing (on hind legs)
 
|-
 
| 0x40
 
| Is mouth open
 
|-
 
| 0x80
 
| ''Unused''
 
|- {{removed}}
 
| {{Metadata id|}}
 
| OptUUID
 
|colspan="2"| Owner
 
| Absent
 
|}
 
 
 
=== Camel ===
 
 
 
{{Metadata inherit|Camel|inherits=Abstract Horse}}
 
 
 
{| class="wikitable"
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{change|{{Metadata id|}}|18}}
 
| Boolean
 
|colspan="2"| Is dashing
 
| False
 
|-
 
| {{change|{{Metadata id|}}|19}}
 
| VarLong
 
|colspan="2"| Last pose change tick
 
| {{change|-52|0}}
 
|}
 
 
 
=== Interaction ===
 
 
 
{{Metadata inherit|Interaction |inherits=Entity|start_at=8}}
 
 
 
{| class="wikitable" {{added}}
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| Width
 
| 1.0
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| Height
 
| 1.0
 
|-
 
| {{Metadata id|}}
 
| Boolean
 
|colspan="2"| Responsive - can be attacked/interacted with if true
 
| false
 
|}
 
 
 
=== Display ===
 
 
 
{{Metadata inherit|Display|inherits=Entity|start_at=8}}
 
 
 
{| class="wikitable" {{added}}
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Interpolation delay
 
| 0
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Interpolation Duration
 
| 0
 
|-
 
| {{Metadata id|}}
 
| Vector3
 
|colspan="2"| Translation
 
| (0.0, 0.0, 0.0)
 
|-
 
| {{Metadata id|}}
 
| Vector3
 
|colspan="2"| Scale
 
| (1.0, 1.0, 1.0)
 
|-
 
| {{Metadata id|}}
 
| Quaternion
 
|colspan="2"| Rotation left
 
| (0.0, 0.0, 0.0, 1.0)
 
|-
 
| {{Metadata id|}}
 
| Quaternion
 
|colspan="2"| Rotation right
 
| (0.0, 0.0, 0.0, 1.0)
 
|-
 
| {{Metadata id|}}
 
| Byte
 
|colspan="2"| Billboard Constraints (0 = FIXED, 1 = VERTICAL, 2 = HORIZONTAL, 3 = CENTER)
 
| 0
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Brightness override (<code>blockLight << 4 | skyLight << 20</code>)
 
| -1
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| View range
 
| 1.0
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| Shadow radius
 
| 0.0
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| Shadow strength
 
| 1.0
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| Width
 
| 0.0
 
|-
 
| {{Metadata id|}}
 
| Float
 
|colspan="2"| Height
 
| 0.0
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Glow color override
 
| -1
 
|}
 
 
 
=== Block Display ===
 
 
 
{{Metadata inherit|Block Display|inherits=Display}}
 
 
 
{| class="wikitable" {{added}}
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{Metadata id|}}
 
| BlockID
 
|colspan="2"| Displayed block state
 
| 0 (Air)
 
|}
 
 
 
=== Item Display ===
 
 
 
{{Metadata inherit|Block Display|inherits=Display}}
 
 
 
{| class="wikitable" {{added}}
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{Metadata id|}}
 
| Slot
 
|colspan="2"| Displayed item
 
| Empty
 
|-
 
| {{Metadata id|}}
 
| Byte
 
|colspan="2"| Display type:
 
* 0 = NONE
 
* 1 = THIRD_PERSON_LEFT_HAND
 
* 2 = THIRD_PERSON_RIGHT_HAND
 
* 3 = FIRST_PERSON_LEFT_HAND
 
* 4 = FIRST_PERSON_RIGHT_HAND
 
* 5 = HEAD
 
* 6 = GUI
 
* 7 = GROUND
 
* 8 = FIXED
 
| 0 (NONE)
 
|}
 
 
 
=== Text Display ===
 
 
 
{{Metadata inherit|Text Display|inherits=Display}}
 
 
 
{| class="wikitable" {{added}}
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{Metadata id|}}
 
| Chat
 
|colspan="2"| Text
 
| Empty
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Line width
 
| 200
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Background color
 
| 1073741824 (0x40000000)
 
|-
 
| {{Metadata id|}}
 
| Byte
 
|colspan="2"| Text opacity
 
| -1 (fully opaque)
 
|-
 
| rowspan="5" | {{Metadata id|}}
 
| rowspan="5" | Byte
 
! Bit mask
 
! Meaning
 
| rowspan="5" | 0
 
|-
 
| 0x01 || Has shadow
 
|-
 
| 0x02 || Is see through
 
|-
 
| 0x04 || Use default background color
 
|-
 
| 0x18 || Alignment:
 
* 0 = CENTER
 
* 1 or 3 = LEFT
 
* 2 = RIGHT
 
|}
 
 
 
=== Sniffer ===
 
 
 
{{Metadata inherit|Axolotl|inherits=Animal|start_at=17}}
 
 
 
{| class="wikitable" {{added}}
 
! Index
 
! Type
 
!style="width: 250px;" colspan="2"| Meaning
 
! Default
 
|-
 
| {{Metadata id|}}
 
| Sniffer State
 
|colspan="2"| Sniffer State
 
| IDLING
 
|-
 
| {{Metadata id|}}
 
| VarInt
 
|colspan="2"| Drop seed at tick
 
| 0
 
|}
 
  
 
== Block Actions ==
 
== Block Actions ==
Line 596: Line 55:
 
=== Clientbound ===
 
=== Clientbound ===
  
==== Bundle Delimiter ====
+
==== Open Sign Editor ====
 
 
The delimeter for a bundle of packets. When received, the client should store every subsequent packet it receives, and wait until another delimiter is received. Once that happens, the client is guaranteed to process every packet in the bundle on the same tick.
 
 
 
The Notchian client doesn't allow more than 4096 packets in the same bundle.
 
 
 
{| class="wikitable" {{added}}
 
! Packet ID
 
! State
 
! Bound To
 
! Field Name
 
! Field Type
 
! Notes
 
|-
 
| 0x00
 
| Play
 
| Client
 
| colspan="3"| ''no fields''
 
|}
 
 
 
==== Chunk Biomes ====
 
  
{| class="wikitable" {{added}}
+
Sent when the client has placed a sign and is allowed to send [[#Update Sign|Update Sign]].  There must already be a sign at the given location (which the client does not do automatically) - send a [[#Block Update|Block Update]] first.
! Packet ID
 
! State
 
! Bound To
 
! colspan="2"| Field Name
 
! colspan="2"| Field Type
 
! Notes
 
|-
 
| rowspan="6"| 0x0D
 
| rowspan="6"| Play
 
| rowspan="6"| Client
 
|-
 
| colspan="2"| Number of chunks
 
| colspan="2"| VarInt
 
| Number of elements in the following array
 
|-
 
| rowspan="4"| Chunk biome data
 
| Chunk X
 
| rowspan="4"| Array
 
| Int
 
| Chunk coordinate (block coordinate divided by 16, rounded down)
 
|-
 
| Chunk Z
 
| Int
 
| Chunk coordinate (block coordinate divided by 16, rounded down)
 
|-
 
| Size
 
| VarInt
 
| Size of Data in bytes
 
|-
 
| Data
 
| Byte array
 
| Chunk [[Chunk Format#Data structure|data structure]], with [[Chunk Format#Chunk_Section|sections]] containing only the <code>Biomes</code> field
 
|}
 
 
 
==== Damage Event ====
 
 
 
{| class="wikitable" {{added}}
 
! Packet ID
 
! State
 
! Bound To
 
! colspan="2"| Field Name
 
! colspan="2"| Field Type
 
! Notes
 
|-
 
| rowspan="9"| 0x18
 
| rowspan="9"| Play
 
| rowspan="9"| Client
 
|-
 
| colspan="2"| Entity ID
 
| colspan="2"| VarInt
 
| The ID of the entity taking damage
 
|-
 
| colspan="2"| Source Type ID
 
| colspan="2"| VarInt
 
| The ID of the type of damage taken
 
|-
 
| colspan="2"| Source Cause ID
 
| colspan="2"| VarInt
 
| The ID + 1 of the entity responsible for the damage, if present. If not present, the value is 0
 
  |-
 
| colspan="2"| Source Direct ID
 
| colspan="2"| VarInt
 
| The ID + 1 of the entity that directly dealt the damage, if present. If not present, the value is 0. If this field is present:
 
* and damage was dealt indirectly, such as by the use of a projectile, this field will contain the ID of such projectile;
 
* and damage was dealt dirctly, such as by manually attacking, this field will contain the same value as Source Cause ID.
 
|-
 
| colspan="2"| Has Source Position
 
| colspan="2"| Boolean
 
| Indicates the presence of the three following fields.
 
The Notchian server sends the Source Position when the damage was dealt by the /damage command and a position was specified
 
|-
 
| colspan="2"| Source Position X
 
| colspan="2"| Optional Double
 
| Only present if Has Source Position is true
 
|-
 
| colspan="2"| Source Position Y
 
| colspan="2"| Optional Double
 
| Only present if Has Source Position is true
 
|-
 
| colspan="2"| Source Position Z
 
| colspan="2"| Optional Double
 
| Only present if Has Source Position is true
 
|}
 
 
 
==== Hurt Animation ====
 
 
 
Plays a bobbing animation for the entity receiving damage.
 
 
 
{| class="wikitable" {{added}}
 
! Packet ID
 
! State
 
! Bound To
 
! colspan="2"| Field Name
 
! colspan="2"| Field Type
 
! Notes
 
|-
 
| rowspan="3"| 0x21
 
| rowspan="3"| Play
 
| rowspan="3"| Client
 
|-
 
| colspan="2"| Entity ID
 
| colspan="2"| VarInt
 
| The ID of the entity taking damage
 
|-
 
| colspan="2"| Yaw
 
| colspan="2"| Float
 
| The direction the damage is coming from in relation to the entity
 
|}
 
 
 
==== Synchronize Player Position ====
 
 
 
Updates the player's position on the server. This packet will also close the “Downloading Terrain” screen when joining/respawning.
 
 
 
If the distance between the last known position of the player on the server and the new position set by this packet is greater than 100 meters, the client will be kicked for “You moved too quickly :( (Hacking?)”.
 
 
 
Also if the fixed-point number of X or Z is set greater than <code>3.2E7D</code> the client will be kicked for “Illegal position”.
 
 
 
Yaw is measured in degrees, and does not follow classical trigonometry rules. The unit circle of yaw on the XZ-plane starts at (0, 1) and turns counterclockwise, with 90 at (-1, 0), 180 at (0, -1) and 270 at (1, 0). Additionally, yaw is not clamped to between 0 and 360 degrees; any number is valid, including negative numbers and numbers greater than 360.
 
 
 
Pitch is measured in degrees, where 0 is looking straight ahead, -90 is looking straight up, and 90 is looking straight down.
 
  
 
{| class="wikitable"
 
{| class="wikitable"
Line 748: Line 67:
 
  ! Notes
 
  ! Notes
 
  |-
 
  |-
  | rowspan="8"| {{change|0x38|0x3C}}
+
  | rowspan="2" | 0x31
  | rowspan="8"| Play
+
  | rowspan="2" | Play
  | rowspan="8"| Client
+
  | rowspan="2" | Client
  | X
+
  | Location
| Double
+
  | Position
| Absolute or relative position, depending on Flags.
+
  |
|-
+
  |- {{added}}
| Y
+
  | Is Front Text
| Double
 
| Absolute or relative position, depending on Flags.
 
|-
 
| Z
 
| Double
 
| Absolute or relative position, depending on Flags.
 
|-
 
| Yaw
 
| Float
 
| Absolute or relative rotation on the X axis, in degrees.
 
|-
 
| Pitch
 
  | Float
 
  | Absolute or relative rotation on the Y axis, in degrees.
 
|-
 
| Flags
 
| Byte
 
| Bit field, see below.
 
|-
 
| Teleport ID
 
| VarInt
 
| Client should confirm this packet with [[#Confirm Teleportation|Confirm Teleportation]] containing the same Teleport ID.
 
  |- {{removed}}
 
  | Dismount Vehicle
 
 
  | Boolean
 
  | Boolean
  | True if the player should dismount their vehicle.
+
  | Whether the opened editor is for the front or on the back of the sign
|}
 
 
 
About the Flags field:
 
 
 
<Dinnerbone> It's a bitfield, X/Y/Z/Y_ROT/X_ROT. If X is set, the x value is relative and not absolute.
 
 
 
{| class="wikitable"
 
|-
 
! Field
 
! Bit
 
|-
 
| X
 
| 0x01
 
|-
 
| Y
 
| 0x02
 
|-
 
| Z
 
| 0x04
 
|-
 
| Y_ROT
 
| 0x08
 
|-
 
| X_ROT
 
| 0x10
 
 
  |}
 
  |}
  
 +
==== Feature Flags ====
  
==== Server Data ====
+
Used to enable and disable features, generally experimental ones, on the client.
  
 
{| class="wikitable"
 
{| class="wikitable"
Line 820: Line 91:
 
  ! Notes
 
  ! Notes
 
  |-
 
  |-
  | rowspan="6"| {{change|0x41|0x45}}
+
  | rowspan="2"| 0x6B
  | rowspan="6"| Play
+
  | rowspan="2"| Play
  | rowspan="6"| Client
+
  | rowspan="2"| Client
  |-{{removed}}
+
  | Total Features
| Has MOTD
+
  | VarInt
| Boolean
+
  | Number of features that appear in the array below.
|
 
|-
 
| MOTD
 
| {{change|Optional Chat|Chat}}
 
|
 
|-
 
| Has Icon
 
| Boolean
 
|
 
|-
 
| Icon
 
  | Optional String (32767)
 
  | Icon PNG base64 String
 
 
  |-
 
  |-
  | Enforces Secure Chat
+
  | Feature Flags
  | Boolean
+
  | Identifier Array
 
  |
 
  |
 
  |}
 
  |}
  
 +
As of {{change|1.19.4|23w12a}}, the following feature flags are available:
 +
 +
* minecraft:vanilla - enables vanilla features</li>
 +
* minecraft:bundle - enables support for the bundle</li>
 +
* {{change|minecraft:update_1_20 - enables all the Minecraft 1.20 features that are available in 1.19.4</li>|}}
  
 
==== Update Recipes ====
 
==== Update Recipes ====
Line 856: Line 119:
 
  ! Notes
 
  ! Notes
 
  |-
 
  |-
  | rowspan="4"| {{change|0x69|0x6D}}
+
  | rowspan="4"| 0x6D
 
  | rowspan="4"| Play
 
  | rowspan="4"| Play
 
  | rowspan="4"| Client
 
  | rowspan="4"| Client
Line 944: Line 207:
 
     | Result
 
     | Result
 
     | [[Slot]]
 
     | [[Slot]]
     |- {{added}}
+
     |-
 
     | Show notification
 
     | Show notification
 
     | Boolean
 
     | Boolean
Line 952: Line 215:
 
  | <code>minecraft:crafting_special_armordye</code>
 
  | <code>minecraft:crafting_special_armordye</code>
 
  | Recipe for dying leather armor
 
  | Recipe for dying leather armor
  | rowspan="13" | As follows:
+
  | rowspan="14" | As follows:
 
   {| class="wikitable"
 
   {| class="wikitable"
 
     ! Name
 
     ! Name
Line 997: Line 260:
 
  |-
 
  |-
 
  | <code>minecraft:crafting_special_suspiciousstew</code>
 
  | <code>minecraft:crafting_special_suspiciousstew</code>
  |
+
  | Recipe for crafting suspicious stews
 +
|-
 +
| <code>minecraft:crafting_decorated_pot</code>
 +
| Recipe for crafting decorated pots
 +
{{change|{{Warning|The Notchian server only sends this recipe if [[Protocol#Feature_Flags|feature flag]] '''update_1_20''' was enabled}}|}}
 
  |-
 
  |-
 
  | <code>minecraft:smelting</code>
 
  | <code>minecraft:smelting</code>
Line 1,061: Line 328:
 
     |
 
     |
 
     |}
 
     |}
  |-
+
  |- {{removed}}
 
  | <code>minecraft:smithing</code>
 
  | <code>minecraft:smithing</code>
 
  | Smithing table recipe
 
  | Smithing table recipe
 +
{{Warning|The Notchian server only sends this recipe if [[Protocol#Feature_Flags|feature flag]] '''update_1_20''' was '''not''' enabled}}
 
  | As follows:
 
  | As follows:
 
   {| class="wikitable"
 
   {| class="wikitable"
Line 1,081: Line 349:
 
     | [[Slot]]
 
     | [[Slot]]
 
     |
 
     |
 +
    |}
 +
|-
 +
| <code>minecraft:smithing_transform</code>
 +
| Recipe for smithing netherite gear
 +
{{change|{{Warning2|The Notchian server only sends this recipe if [[Protocol#Feature_Flags|feature flag]] '''update_1_20''' was enabled. It supersedes the <code>minecraft:smithing</code> recipe type}}|}}
 +
| As follows:
 +
  {| class="wikitable"
 +
    ! Name
 +
    ! Type
 +
    ! Description
 +
    |-
 +
    | Template
 +
    | Ingredient
 +
    | The smithing template.
 +
    |-
 +
    | Base
 +
    | Ingredient
 +
    | The base item.
 +
    |-
 +
    | Addition
 +
    | Ingredient
 +
    | The additional ingredient.
 +
    |-
 +
    | Result
 +
    | [[Slot]]
 +
    |
 +
    |}
 +
|-
 +
| <code>minecraft:smithing_trim</code>
 +
| Recipe for applying armor trims
 +
{{change|{{Warning2|The Notchian server only sends this recipe if [[Protocol#Feature_Flags|feature flag]] '''update_1_20''' was enabled. It supersedes the <code>minecraft:smithing</code> recipe type}}|}}
 +
| As follows:
 +
  {| class="wikitable"
 +
    ! Name
 +
    ! Type
 +
    ! Description
 +
    |-
 +
    | Template
 +
    | Ingredient
 +
    | The smithing template.
 +
    |-
 +
    | Base
 +
    | Ingredient
 +
    | The base item.
 +
    |-
 +
    | Addition
 +
    | Ingredient
 +
    | The additional ingredient.
 
     |}
 
     |}
 
  |}
 
  |}
Line 1,102: Line 418:
 
=== Serverbound ===
 
=== Serverbound ===
  
No changes so far.
+
==== Update Sign ====
 +
 
 +
This message is sent from the client to the server when the “Done” button is pushed after placing a sign.
 +
 
 +
The server only accepts this packet after [[#Open Sign Editor|Open Sign Editor]], otherwise this packet is silently ignored.
 +
 
 +
{| class="wikitable"
 +
! Packet ID
 +
! State
 +
! Bound To
 +
! Field Name
 +
! Field Type
 +
! Notes
 +
|-
 +
| rowspan="6"| 0x2E
 +
| rowspan="6"| Play
 +
| rowspan="6"| Server
 +
| Location
 +
| Position
 +
| Block Coordinates.
 +
|- {{added}}
 +
| Is Front Text
 +
| Boolean
 +
| Whether the updated text is in front or on the back of the sign
 +
|-
 +
| Line 1
 +
| String (384)
 +
| First line of text in the sign.
 +
|-
 +
| Line 2
 +
| String (384)
 +
| Second line of text in the sign.
 +
|-
 +
| Line 3
 +
| String (384)
 +
| Third line of text in the sign.
 +
|-
 +
| Line 4
 +
| String (384)
 +
| Fourth line of text in the sign.
 +
|}
  
 
== Status ==
 
== Status ==

Revision as of 00:12, 30 March 2023

This page documents the changes from the last stable Minecraft release (currently 1.19.4, protocol 762) to the current pre-release (currently 23w13a, protocol Snapshot 128). Note that this page contains bleeding-edge information that may not be completely or correctly documented.

One who wishes to commandeer the merging of this into Protocol when an update is made must be sure to respect any changes that may have occurred to the respective packets there.

Contents

Data types

No changes so far.

Packets

ID Packet name Documentation
Play clientbound
0x31 Open Sign Editor Current Pre
0x6B Feature Flags Current Pre
0x6D Update Recipes Current Pre
Play serverbound
0x2E Update Sign Current Pre

New/modified data types

No changes so far.

Entity Metadata

No changes so far.

Entity

No changes so far.

Block Actions

No changes so far.

Inventories

No changes so far.

Plugin Channels

No changes so far.

Play

Clientbound

Open Sign Editor

Sent when the client has placed a sign and is allowed to send Update Sign. There must already be a sign at the given location (which the client does not do automatically) - send a Block Update first.

Packet ID State Bound To Field Name Field Type Notes
0x31 Play Client Location Position
Is Front Text Boolean Whether the opened editor is for the front or on the back of the sign

Feature Flags

Used to enable and disable features, generally experimental ones, on the client.

Packet ID State Bound To Field Name Field Type Notes
0x6B Play Client Total Features VarInt Number of features that appear in the array below.
Feature Flags Identifier Array

As of 1.19.4 23w12a, the following feature flags are available:

  • minecraft:vanilla - enables vanilla features
  • minecraft:bundle - enables support for the bundle
  • minecraft:update_1_20 - enables all the Minecraft 1.20 features that are available in 1.19.4

Update Recipes

Packet ID State Bound To Field Name Field Type Notes
0x6D Play Client Num Recipes VarInt Number of elements in the following array.
Recipe Type Array Identifier The recipe type, see below.
Recipe ID Identifier
Data Varies Additional data for the recipe.

Recipe types:

Type Description Data
minecraft:crafting_shapeless Shapeless crafting recipe. All items in the ingredient list must be present, but in any order/slot. As follows:
Name Type Description
Group String Used to group similar recipes together in the recipe book. Tag is present in recipe JSON.
Category VarInt Enum Building = 0, Redstone = 1, Equipment = 2, Misc = 3
Ingredient count VarInt Number of elements in the following array.
Ingredients Array of Ingredient.
Result Slot
minecraft:crafting_shaped Shaped crafting recipe. All items must be present in the same pattern (which may be flipped horizontally or translated). As follows:
Name Type Description
Width VarInt
Height VarInt
Group String Used to group similar recipes together in the recipe book. Tag is present in recipe JSON.
Category VarInt Enum Building = 0, Redstone = 1, Equipment = 2, Misc = 3
Ingredients Array of Ingredient Length is width * height. Indexed by x + (y * width).
Result Slot
Show notification Boolean Show a toast when the recipe is added.
minecraft:crafting_special_armordye Recipe for dying leather armor As follows:
Name Type Description
Category VarInt Enum Building = 0, Redstone = 1, Equipment = 2, Misc = 3
minecraft:crafting_special_bookcloning Recipe for copying contents of written books
minecraft:crafting_special_mapcloning Recipe for copying maps
minecraft:crafting_special_mapextending Recipe for adding paper to maps
minecraft:crafting_special_firework_rocket Recipe for making firework rockets
minecraft:crafting_special_firework_star Recipe for making firework stars
minecraft:crafting_special_firework_star_fade Recipe for making firework stars fade between multiple colors
minecraft:crafting_special_repairitem Recipe for repairing items via crafting
minecraft:crafting_special_tippedarrow Recipe for crafting tipped arrows
minecraft:crafting_special_bannerduplicate Recipe for copying banner patterns
minecraft:crafting_special_shielddecoration Recipe for applying a banner's pattern to a shield
minecraft:crafting_special_shulkerboxcoloring Recipe for recoloring a shulker box
minecraft:crafting_special_suspiciousstew Recipe for crafting suspicious stews
minecraft:crafting_decorated_pot Recipe for crafting decorated pots

Warning.png The Notchian server only sends this recipe if feature flag update_1_20 was enabled

minecraft:smelting Smelting recipe As follows:
Name Type Description
Group String Used to group similar recipes together in the recipe book.
Category VarInt Enum Food = 0, Blocks = 1, Misc = 2
Ingredient Ingredient
Result Slot
Experience Float
Cooking time VarInt
minecraft:blasting Blast furnace recipe
minecraft:smoking Smoker recipe
minecraft:campfire_cooking Campfire recipe
minecraft:stonecutting Stonecutter recipe As follows:
Name Type Description
Group String Used to group similar recipes together in the recipe book. Tag is present in recipe JSON.
Ingredient Ingredient
Result Slot
minecraft:smithing Smithing table recipe

Warning.png The Notchian server only sends this recipe if feature flag update_1_20 was not enabled

As follows:
Name Type Description
Base Ingredient First item.
Addition Ingredient Second item.
Result Slot
minecraft:smithing_transform Recipe for smithing netherite gear

Warning.png The Notchian server only sends this recipe if feature flag update_1_20 was enabled. It supersedes the minecraft:smithing recipe type

As follows:
Name Type Description
Template Ingredient The smithing template.
Base Ingredient The base item.
Addition Ingredient The additional ingredient.
Result Slot
minecraft:smithing_trim Recipe for applying armor trims

Warning.png The Notchian server only sends this recipe if feature flag update_1_20 was enabled. It supersedes the minecraft:smithing recipe type

As follows:
Name Type Description
Template Ingredient The smithing template.
Base Ingredient The base item.
Addition Ingredient The additional ingredient.

Ingredient is defined as:

Name Type Description
Count VarInt Number of elements in the following array.
Items Array of Slot Any item in this array may be used for the recipe. The count of each item should be 1.

Serverbound

Update Sign

This message is sent from the client to the server when the “Done” button is pushed after placing a sign.

The server only accepts this packet after Open Sign Editor, otherwise this packet is silently ignored.

Packet ID State Bound To Field Name Field Type Notes
0x2E Play Server Location Position Block Coordinates.
Is Front Text Boolean Whether the updated text is in front or on the back of the sign
Line 1 String (384) First line of text in the sign.
Line 2 String (384) Second line of text in the sign.
Line 3 String (384) Third line of text in the sign.
Line 4 String (384) Fourth line of text in the sign.

Status

Clientbound

No changes so far.

Serverbound

No changes so far.

Login

Clientbound

No changes so far.

Serverbound

No changes so far.