Packet 30
InventoryTransactionPacket
Inventory Transaction. Sent for item interaction UI depending on if ItemStackNetManager is enabled as well as when the player uses items in gameplay. See ComplexInventoryTransaction::Type for more details.
HeaderID 30varuint
0Legacy Request IDItemStackLegacyRequestId · variable
1Legacy Set Item Slotsarray<LegacySetSlot> · variable
2TransactiononeOf<NormalTransactionData, InventoryMismatchData, ItemUseInventoryTransaction, ItemUseOnActorInventoryTransaction, ItemReleaseInventoryTransaction> · variable
Serialized fields
3 top-level fields0Legacy Request IDUsed when ItemStackNetManager is enabled. Identifies a legacy client item request. Negative, even values are valid. Zero indicates no legacy request.ItemStackLegacyRequestId
- 0IDRaw Id (32 bit signed)Compression
varint32
1Legacy Set Item SlotsoptionalOnly present when Legacy Request ID is valid. Lists the open containers and their slot indices the client is requesting changes for.LegacySetSlotas
array<LegacySetSlot>0Container EnumThe container enum name identifying which container slot set this belongs to.CompressionEnum-as-ValueContainerEnumNameas
uint8- 0
AnvilInputContainer - 1
AnvilMaterialContainer - 2
AnvilResultPreviewContainer - 3
SmithingTableInputContainer - 4
SmithingTableMaterialContainer - 5
SmithingTableResultPreviewContainer - 6
ArmorContainer - 7
LevelEntityContainer - 8
BeaconPaymentContainer - 9
BrewingStandInputContainer - 10
BrewingStandResultContainer - 11
BrewingStandFuelContainer - 12
CombinedHotbarAndInventoryContainer - 13
CraftingInputContainer - 14
CraftingOutputPreviewContainer - 15
RecipeConstructionContainer - 16
RecipeNatureContainer - 17
RecipeItemsContainer - 18
RecipeFoodContainer - 19
RecipeBlocksContainer - 20
RecipeFurnaceItemsContainer - 21
RecipeSearchContainer - 22
RecipeSearchBarContainer - 23
RecipeEquipmentContainer - 24
RecipeBookContainer - 25
EnchantingInputContainer - 26
EnchantingMaterialContainer - 27
FurnaceFuelContainer - 28
FurnaceIngredientContainer - 29
FurnaceResultContainer - 30
HorseEquipContainer - 31
HotbarContainer - 32
InventoryContainer - 33
ShulkerBoxContainer - 34
TradeIngredient1Container - 35
TradeIngredient2Container - 36
TradeResultPreviewContainer - 37
OffhandContainer - 38
CompoundCreatorInput - 39
CompoundCreatorOutputPreview - 40
ElementConstructorOutputPreview - 41
MaterialReducerInput - 42
MaterialReducerOutput - 43
LabTableInput - 44
LoomInputContainer - 45
LoomDyeContainer - 46
LoomMaterialContainer - 47
LoomResultPreviewContainer - 48
BlastFurnaceIngredientContainer - 49
SmokerIngredientContainer - 50
Trade2Ingredient1Container - 51
Trade2Ingredient2Container - 52
Trade2ResultPreviewContainer - 53
GrindstoneInputContainer - 54
GrindstoneAdditionalContainer - 55
GrindstoneResultPreviewContainer - 56
StonecutterInputContainer - 57
StonecutterResultPreviewContainer - 58
CartographyInputContainer - 59
CartographyAdditionalContainer - 60
CartographyResultPreviewContainer - 61
BarrelContainer - 62
CursorContainer - 63
CreatedOutputContainer - 64
SmithingTableTemplateContainer - 65
CrafterLevelEntityContainer - 66
DynamicContainer
- 0
- 1SlotsList of inventory slot indices within the given container.
array<uint8>
2TransactionThe inventory transaction. The variant index encodes ComplexInventoryTransaction::Type (0=Normal, 1=Mismatch, 2=ItemUse, 3=ItemUseOnActor, 4=ItemRelease), matching the legacy wire format discriminator.
oneOf<NormalTransactionData, InventoryMismatchData, ItemUseInventoryTransaction, ItemUseOnActorInventoryTransaction, ItemReleaseInventoryTransaction>0NormalTransactionData
NormalTransactionData0ActionsBase inventory actions. Lists the slot changes making up this Normal (container UI) transaction.InventoryTransaction
0ActionsList of inventory slot changes. Each action describes which container slot is changing and what the item descriptor transitions from and to.InventoryActionas
array<InventoryAction>0SourceThe inventory source identifying which container this action targets.InventorySource
0Source TypeThe inventory source type.CompressionEnum-as-ValueInventorySourceTypeas
varuint32- 0
Container Inventory - 1
Global Inventory - 2
World Interaction - 3
Creative Inventory - 4
Non Implemented Feature TODO
- 0
2Bit FlagsoptionalSource flags. Present only for WorldInteraction source type.CompressionEnum-as-ValueInventorySourceFlagsas
varuint32- 0
No Flag - 1
World Interaction Random
- 0
- 1SlotThe slot index within the source container.Compression
varuint32 - 2From ItemThe item descriptor representing the state of the slot before this action.NetworkItemStackDescriptor
- 3To ItemThe item descriptor representing the desired state of the slot after this action.NetworkItemStackDescriptor
1InventoryMismatchData
InventoryMismatchData0ActionsBase inventory actions. Lists the slot changes making up this server-to-client rejection transaction.InventoryTransaction
0ActionsList of inventory slot changes. Each action describes which container slot is changing and what the item descriptor transitions from and to.InventoryActionas
array<InventoryAction>0SourceThe inventory source identifying which container this action targets.InventorySource
0Source TypeThe inventory source type.CompressionEnum-as-ValueInventorySourceTypeas
varuint32- 0
Container Inventory - 1
Global Inventory - 2
World Interaction - 3
Creative Inventory - 4
Non Implemented Feature TODO
- 0
2Bit FlagsoptionalSource flags. Present only for WorldInteraction source type.CompressionEnum-as-ValueInventorySourceFlagsas
varuint32- 0
No Flag - 1
World Interaction Random
- 0
- 1SlotThe slot index within the source container.Compression
varuint32 - 2From ItemThe item descriptor representing the state of the slot before this action.NetworkItemStackDescriptor
- 3To ItemThe item descriptor representing the desired state of the slot after this action.NetworkItemStackDescriptor
2ItemUseInventoryTransaction
ItemUseInventoryTransaction0ActionsBase inventory actions. Lists the inventory slot changes associated with this transaction.InventoryTransaction
0ActionsList of inventory slot changes. Each action describes which container slot is changing and what the item descriptor transitions from and to.InventoryActionas
array<InventoryAction>0SourceThe inventory source identifying which container this action targets.InventorySource
0Source TypeThe inventory source type.CompressionEnum-as-ValueInventorySourceTypeas
varuint32- 0
Container Inventory - 1
Global Inventory - 2
World Interaction - 3
Creative Inventory - 4
Non Implemented Feature TODO
- 0
2Bit FlagsoptionalSource flags. Present only for WorldInteraction source type.CompressionEnum-as-ValueInventorySourceFlagsas
varuint32- 0
No Flag - 1
World Interaction Random
- 0
- 1SlotThe slot index within the source container.Compression
varuint32 - 2From ItemThe item descriptor representing the state of the slot before this action.NetworkItemStackDescriptor
- 3To ItemThe item descriptor representing the desired state of the slot after this action.NetworkItemStackDescriptor
1Action TypeThe type of item use action performed.CompressionEnum-as-ValueItemUseActionTypeas
varint32- 0
Place - 1
Use - 2
Destroy - 3
Use As Attack
- 0
2Trigger TypePlayerInput if a direct result of the player's initial button input. SimulationTick if the player is holding down input from a previous tick.CompressionEnum-as-ValueItemUseTriggerTypeas
uint8- 0
Unknown - 1
Player Input - 2
Simulation Tick
- 0
- 4FaceThe face of the target block that was clicked.Compression
uint8 - 5SlotThe inventory slot of the item being used.Compression
varint32 - 7ItemThe item stack descriptor of the item being used.NetworkItemStackDescriptor
- 10Target Block IdThe runtime block state ID of the target block.Compression
varuint32 11Client Interact PredictionWhether the client predicted the interaction would succeed.Enum-as-ValueItemUsePredictedResultas
uint8- 0
Failure - 1
Success
- 0
12Client Cooldown StateWhether the item is currently on cooldown on the client.Enum-as-ValueItemUseClientCooldownStateas
uint8- 0
Off - 1
On
- 0
3ItemUseOnActorInventoryTransaction
ItemUseOnActorInventoryTransaction0ActionsBase inventory actions. Lists the inventory slot changes associated with this transaction.InventoryTransaction
0ActionsList of inventory slot changes. Each action describes which container slot is changing and what the item descriptor transitions from and to.InventoryActionas
array<InventoryAction>0SourceThe inventory source identifying which container this action targets.InventorySource
0Source TypeThe inventory source type.CompressionEnum-as-ValueInventorySourceTypeas
varuint32- 0
Container Inventory - 1
Global Inventory - 2
World Interaction - 3
Creative Inventory - 4
Non Implemented Feature TODO
- 0
2Bit FlagsoptionalSource flags. Present only for WorldInteraction source type.CompressionEnum-as-ValueInventorySourceFlagsas
varuint32- 0
No Flag - 1
World Interaction Random
- 0
- 1SlotThe slot index within the source container.Compression
varuint32 - 2From ItemThe item descriptor representing the state of the slot before this action.NetworkItemStackDescriptor
- 3To ItemThe item descriptor representing the desired state of the slot after this action.NetworkItemStackDescriptor
1Runtime IdThe runtime ID of the actor being interacted with or attacked.ActorRuntimeID
- 0Actor Runtime IDCompression
varuint64
2Action TypeInteract: right-click on actor. Attack: left-click or trident spin attack.CompressionEnum-as-ValueItemUseOnActorActionTypeas
varint32- 0
Interact - 1
Attack - 2
Item Interact
- 0
- 3SlotThe inventory slot of the item being used on the actor.Compression
varint32 - 4ItemThe item stack descriptor of the item being used on the actor.NetworkItemStackDescriptor
4ItemReleaseInventoryTransaction
ItemReleaseInventoryTransaction0ActionsBase inventory actions. Lists the inventory slot changes associated with this transaction.InventoryTransaction
0ActionsList of inventory slot changes. Each action describes which container slot is changing and what the item descriptor transitions from and to.InventoryActionas
array<InventoryAction>0SourceThe inventory source identifying which container this action targets.InventorySource
0Source TypeThe inventory source type.CompressionEnum-as-ValueInventorySourceTypeas
varuint32- 0
Container Inventory - 1
Global Inventory - 2
World Interaction - 3
Creative Inventory - 4
Non Implemented Feature TODO
- 0
2Bit FlagsoptionalSource flags. Present only for WorldInteraction source type.CompressionEnum-as-ValueInventorySourceFlagsas
varuint32- 0
No Flag - 1
World Interaction Random
- 0
- 1SlotThe slot index within the source container.Compression
varuint32 - 2From ItemThe item descriptor representing the state of the slot before this action.NetworkItemStackDescriptor
- 3To ItemThe item descriptor representing the desired state of the slot after this action.NetworkItemStackDescriptor
1Action TypeRelease: firing a bow or releasing a held item. Use: finishing charging a crossbow.CompressionEnum-as-ValueItemReleaseActionTypeas
varint32- 0
Release - 1
Use
- 0
- 2SlotThe inventory slot of the item being released.Compression
varint32 - 3ItemThe item stack descriptor of the item being released.NetworkItemStackDescriptor
Changelog
Stable releases
Changes between stable protocol releases.
- Released
- Protocol
- 2193
Packet
1 entryChanged 1
- Added supporting type
HandSlot: Added enum type. - Added supporting type
HandSlot: Added enum valueMainhandwith value0. - Added supporting type
HandSlot: Added enum valueOffhandwith value1. - Changed supporting type
ItemUseInventoryTransaction: Added fieldHand(typeuint8). - Changed supporting type
ItemUseInventoryTransaction: MovedItemfrom field 6 to 7. - Changed supporting type
ItemUseInventoryTransaction: MovedFrom Positionfrom field 7 to 8. - Changed supporting type
ItemUseInventoryTransaction: MovedClick Positionfrom field 8 to 9. - Changed supporting type
ItemUseInventoryTransaction: MovedTarget Block Idfrom field 9 to 10. - Changed supporting type
ItemUseInventoryTransaction: MovedClient Interact Predictionfrom field 10 to 11. - Changed supporting type
ItemUseInventoryTransaction: MovedClient Cooldown Statefrom field 11 to 12.
All builds
Changes between consecutive stable releases and preview builds.
- Released
- Protocol
- 2207
- Previous build
- 1.26.51
Packet
1 entryChanged 1
- Changed supporting type
ContainerEnumName: Changed enum valueRecipeFoodContainerfrom18to64. - Changed supporting type
ContainerEnumName: Changed enum valueRecipeBlocksContainerfrom19to65. - Changed supporting type
ContainerEnumName: Changed enum valueRecipeFurnaceItemsContainerfrom20to66. - Changed supporting type
ContainerEnumName: Changed enum valueRecipeSearchContainerfrom21to18. - Changed supporting type
ContainerEnumName: Changed enum valueRecipeSearchBarContainerfrom22to19. - Changed supporting type
ContainerEnumName: Changed enum valueRecipeEquipmentContainerfrom23to20. - Changed supporting type
ContainerEnumName: Changed enum valueRecipeBookContainerfrom24to21. - Changed supporting type
ContainerEnumName: Changed enum valueEnchantingInputContainerfrom25to22. - Changed supporting type
ContainerEnumName: Changed enum valueEnchantingMaterialContainerfrom26to23. - Changed supporting type
ContainerEnumName: Changed enum valueFurnaceFuelContainerfrom27to24. - Changed supporting type
ContainerEnumName: Changed enum valueFurnaceIngredientContainerfrom28to25. - Changed supporting type
ContainerEnumName: Changed enum valueFurnaceResultContainerfrom29to26. - Changed supporting type
ContainerEnumName: Changed enum valueHorseEquipContainerfrom30to27. - Changed supporting type
ContainerEnumName: Changed enum valueHotbarContainerfrom31to28. - Changed supporting type
ContainerEnumName: Changed enum valueInventoryContainerfrom32to29. - Changed supporting type
ContainerEnumName: Changed enum valueShulkerBoxContainerfrom33to30. - Changed supporting type
ContainerEnumName: Changed enum valueTradeIngredient1Containerfrom34to31. - Changed supporting type
ContainerEnumName: Changed enum valueTradeIngredient2Containerfrom35to32. - Changed supporting type
ContainerEnumName: Changed enum valueTradeResultPreviewContainerfrom36to33. - Changed supporting type
ContainerEnumName: Changed enum valueOffhandContainerfrom37to34. - Changed supporting type
ContainerEnumName: Changed enum valueCompoundCreatorInputfrom38to35. - Changed supporting type
ContainerEnumName: Changed enum valueCompoundCreatorOutputPreviewfrom39to36. - Changed supporting type
ContainerEnumName: Changed enum valueElementConstructorOutputPreviewfrom40to37. - Changed supporting type
ContainerEnumName: Changed enum valueMaterialReducerInputfrom41to38. - Changed supporting type
ContainerEnumName: Changed enum valueMaterialReducerOutputfrom42to39. - Changed supporting type
ContainerEnumName: Changed enum valueLabTableInputfrom43to40. - Changed supporting type
ContainerEnumName: Changed enum valueLoomInputContainerfrom44to41. - Changed supporting type
ContainerEnumName: Changed enum valueLoomDyeContainerfrom45to42. - Changed supporting type
ContainerEnumName: Changed enum valueLoomMaterialContainerfrom46to43. - Changed supporting type
ContainerEnumName: Changed enum valueLoomResultPreviewContainerfrom47to44. - Changed supporting type
ContainerEnumName: Changed enum valueBlastFurnaceIngredientContainerfrom48to45. - Changed supporting type
ContainerEnumName: Changed enum valueSmokerIngredientContainerfrom49to46. - Changed supporting type
ContainerEnumName: Changed enum valueTrade2Ingredient1Containerfrom50to47. - Changed supporting type
ContainerEnumName: Changed enum valueTrade2Ingredient2Containerfrom51to48. - Changed supporting type
ContainerEnumName: Changed enum valueTrade2ResultPreviewContainerfrom52to49. - Changed supporting type
ContainerEnumName: Changed enum valueGrindstoneInputContainerfrom53to50. - Changed supporting type
ContainerEnumName: Changed enum valueGrindstoneAdditionalContainerfrom54to51. - Changed supporting type
ContainerEnumName: Changed enum valueGrindstoneResultPreviewContainerfrom55to52. - Changed supporting type
ContainerEnumName: Changed enum valueStonecutterInputContainerfrom56to53. - Changed supporting type
ContainerEnumName: Changed enum valueStonecutterResultPreviewContainerfrom57to54. - Changed supporting type
ContainerEnumName: Changed enum valueCartographyInputContainerfrom58to55. - Changed supporting type
ContainerEnumName: Changed enum valueCartographyAdditionalContainerfrom59to56. - Changed supporting type
ContainerEnumName: Changed enum valueCartographyResultPreviewContainerfrom60to57. - Changed supporting type
ContainerEnumName: Changed enum valueBarrelContainerfrom61to58. - Changed supporting type
ContainerEnumName: Changed enum valueCursorContainerfrom62to59. - Changed supporting type
ContainerEnumName: Changed enum valueCreatedOutputContainerfrom63to60. - Changed supporting type
ContainerEnumName: Changed enum valueSmithingTableTemplateContainerfrom64to61. - Changed supporting type
ContainerEnumName: Changed enum valueCrafterLevelEntityContainerfrom65to62. - Changed supporting type
ContainerEnumName: Changed enum valueDynamicContainerfrom66to63. - Changed supporting type
InventorySourceType: Changed enum valueNon Implemented Feature TODOfrom4to99999. - Changed supporting type
ItemReleaseInventoryTransaction: Added fieldHand(typeuint8). - Changed supporting type
ItemUseOnActorInventoryTransaction: Added fieldHand(typeuint8). - Changed supporting type
ItemUseOnActorInventoryTransaction: MovedItemfrom field 4 to 5. - Changed supporting type
ItemUseOnActorInventoryTransaction: MovedFrom Positionfrom field 5 to 6. - Changed supporting type
ItemUseOnActorInventoryTransaction: MovedHit Positionfrom field 6 to 7.
- Released
- Protocol
- 2192
- Previous build
- 1.26.50-preview.25
Packet
1 entryChanged 1
- Added supporting type
HandSlot: Added enum type. - Added supporting type
HandSlot: Added enum valueMainhandwith value0. - Added supporting type
HandSlot: Added enum valueOffhandwith value1. - Changed supporting type
ItemUseInventoryTransaction: Added fieldHand(typeuint8). - Changed supporting type
ItemUseInventoryTransaction: MovedItemfrom field 6 to 7. - Changed supporting type
ItemUseInventoryTransaction: MovedFrom Positionfrom field 7 to 8. - Changed supporting type
ItemUseInventoryTransaction: MovedClick Positionfrom field 8 to 9. - Changed supporting type
ItemUseInventoryTransaction: MovedTarget Block Idfrom field 9 to 10. - Changed supporting type
ItemUseInventoryTransaction: MovedClient Interact Predictionfrom field 10 to 11. - Changed supporting type
ItemUseInventoryTransaction: MovedClient Cooldown Statefrom field 11 to 12.