Package cn.nukkit.inventory
Class ShulkerBoxInventory
java.lang.Object
cn.nukkit.inventory.BaseInventory
cn.nukkit.inventory.ContainerInventory
cn.nukkit.inventory.ShulkerBoxInventory
- All Implemented Interfaces:
Inventory
- Author:
- PetteriM1
-
Field Summary
Fields inherited from class cn.nukkit.inventory.BaseInventory
AIR_ITEM, holder, maxStackSize, name, size, slots, title, type, viewers
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
canAddItem
(Item item) boolean
若返回为true,则在inventory打开和关闭时会发生振动事件 (InventoryHolder为Vector3子类的前提下)void
void
void
Methods inherited from class cn.nukkit.inventory.ContainerInventory
calculateRedstone
Methods inherited from class cn.nukkit.inventory.BaseInventory
addItem, addListener, all, clear, clearAll, close, contains, decreaseCount, first, firstEmpty, getContents, getFreeSpace, getItem, getMaxStackSize, getName, getSize, getTitle, getType, getUnclonedItem, getViewers, isEmpty, isFull, onSlotChange, open, remove, removeItem, removeListener, sendContents, sendContents, sendContents, sendSlot, sendSlot, setContents, setItem, setMaxStackSize, setSize
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface cn.nukkit.inventory.Inventory
clear, first, setItem, setItemByPlayer
-
Constructor Details
-
ShulkerBoxInventory
-
-
Method Details
-
getHolder
- Specified by:
getHolder
in interfaceInventory
- Overrides:
getHolder
in classBaseInventory
-
onOpen
@PowerNukkitDifference(info="Using new method to play sounds", since="1.4.0.0-PN") public void onOpen(Player who) - Specified by:
onOpen
in interfaceInventory
- Overrides:
onOpen
in classContainerInventory
-
onClose
@PowerNukkitDifference(info="Using new method to play sounds", since="1.4.0.0-PN") public void onClose(Player who) - Specified by:
onClose
in interfaceInventory
- Overrides:
onClose
in classContainerInventory
-
canAddItem
- Specified by:
canAddItem
in interfaceInventory
- Overrides:
canAddItem
in classBaseInventory
-
sendSlot
- Specified by:
sendSlot
in interfaceInventory
- Overrides:
sendSlot
in classBaseInventory
-
canCauseVibration
public boolean canCauseVibration()Description copied from class:ContainerInventory
若返回为true,则在inventory打开和关闭时会发生振动事件 (InventoryHolder为Vector3子类的前提下)- Overrides:
canCauseVibration
in classContainerInventory
- Returns:
- boolean
-