@@ -43,6 +43,14 @@ const option4 = (packet: ByteBuffer): ItemInteraction => {
43
43
return { widgetId, containerId, itemId, slot } ;
44
44
} ;
45
45
46
+ const inventoryOption1 = ( packet : ByteBuffer ) : ItemInteraction => {
47
+ const slot = packet . get ( 'SHORT' , 'UNSIGNED' , 'LITTLE_ENDIAN' ) ;
48
+ const itemId = packet . get ( 'SHORT' , 'SIGNED' , 'LITTLE_ENDIAN' ) ;
49
+ const containerId = packet . get ( 'SHORT' , 'SIGNED' , 'LITTLE_ENDIAN' ) ;
50
+ const widgetId = packet . get ( 'SHORT' , 'UNSIGNED' ) ;
51
+ return { widgetId, containerId, itemId, slot } ;
52
+ } ;
53
+
46
54
const inventoryOption4 = ( packet : ByteBuffer ) : ItemInteraction => {
47
55
const slot = packet . get ( 'SHORT' , 'UNSIGNED' ) ;
48
56
const widgetId = packet . get ( 'SHORT' , 'SIGNED' , 'LITTLE_ENDIAN' ) ;
@@ -58,6 +66,7 @@ export const itemInteractionPacket: incomingPacket = (player: Player, packetId:
58
66
26 : { packetDef : option3 , optionNumber : 3 } ,
59
67
147 : { packetDef : option4 , optionNumber : 4 } ,
60
68
98 : { packetDef : inventoryOption4 , optionNumber : 4 } ,
69
+ 240 : { packetDef : inventoryOption1 , optionNumber : 1 } ,
61
70
} ;
62
71
63
72
const packetDetails = packets [ packetId ] ;
0 commit comments