C0EPacketClickWindow
Sent when clicking in a window/inventory slot
Extends
Constructors
Constructor
new C0EPacketClickWindow(
windowId,slotId,button,mode,itemStack,transactionId):C0EPacketClickWindow
Creates a new click window packet
Parameters
windowId
number
windowId - The ID of the window being clicked
slotId
number
slotId - The ID of the slot being clicked
button
number
button - The button used (0=left, 1=right)
mode
number
mode - The click mode (0=normal click, 1=shift click, 2=key drop, 3=middle click, 4=drop w/ctrl key, 5=paint w/drag, 6=double click)
itemStack
itemStack - The ItemStack in the clicked slot
transactionId
number
transactionId - The transaction ID
Returns
C0EPacketClickWindow
Overrides
Packet.constructor
Methods
getButton()
getButton():
number
Gets the mouse button used (0=left, 1=right)
Returns
number
Button used
getItemStack()
getItemStack():
ItemStack
Gets the ItemStack in the clicked slot
Returns
ItemStack in slot
getMode()
getMode():
number
Gets the click mode (0=click, 1=shift-click, etc)
Returns
number
Click mode
getPacketID()
getPacketID():
string
Get the ID of the packet.
Returns
string
The ID of the packet.
Inherited from
getSlotId()
getSlotId():
number
Gets the ID of the clicked slot
Returns
number
Slot ID
getWindowId()
getWindowId():
number
Gets the ID of the window being clicked
Returns
number
Window ID
setButton()
setButton(
button):void
Sets the button used
Parameters
button
number
button - The new button (0=left, 1=right)
Returns
void
setItemStack()
setItemStack(
itemStack):void
Sets the ItemStack
Parameters
itemStack
itemStack - The new ItemStack for this slot
Returns
void
setMode()
setMode(
mode):void
Sets the click mode
Parameters
mode
number
mode - The new mode (0=click, 1=shift-click, etc)
Returns
void
setSlotId()
setSlotId(
slotId):void
Sets the slot ID
Parameters
slotId
number
slotId - The new slot ID
Returns
void
setWindowId()
setWindowId(
windowId):void
Sets the window ID
Parameters
windowId
number
windowId - The new window ID
Returns
void
Last updated