Package hiiragi283.core.common.inventory
Class HTContainerItemSlot
-
- All Implemented Interfaces:
public class HTContainerItemSlot extends SlotHTItemSlotに基づいたSlotの実装
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public enumHTContainerItemSlot.Type
-
Field Summary
Fields Modifier and Type Field Description private final HTItemSlotslotprivate final HTContainerItemSlot.TypeslotTypeprivate final BooleanisActiveprivate final Pair<ResourceLocation, ResourceLocation>noItemIconprivate final IntegermaxStackSizeprivate final IntegerslotIndexprivate final ItemStackitemprivate final IntegercontainerSlotprivate final BooleanisFakeprivate final BooleanisHighlightablepublic final Containercontainerpublic final Integerindexpublic final Integerxpublic final Integery
-
Constructor Summary
Constructors Constructor Description HTContainerItemSlot(HTItemSlot slot, Integer x, Integer y, Consumer<ItemStack> stackSetter, Function2<HTItemResourceType, HTStorageAccess, Boolean> manualFilter, HTContainerItemSlot.Type slotType)HTContainerItemSlot(HTItemSlot.Basic slot, Integer x, Integer y, HTContainerItemSlot.Type slotType)
-
Method Summary
Modifier and Type Method Description final HTItemSlotgetSlot()final HTContainerItemSlot.TypegetSlotType()final UnitupdateCount(Integer count)BooleanmayPlace(ItemStack stack)ItemStackgetItem()BooleanhasItem()Unitset(ItemStack stack)UnitsetChanged()IntegergetMaxStackSize()IntegergetMaxStackSize(ItemStack stack)BooleanmayPickup(Player player)ItemStackremove(Integer amount)Optional<ItemStack>tryRemove(Integer count, Integer decrement, Player player)final static HTContainerItemSlotinput(HTItemSlot.Basic slot, Integer x, Integer y)final static HTContainerItemSlotoutput(HTItemSlot.Basic slot, Integer x, Integer y)final static HTContainerItemSlotboth(HTItemSlot.Basic slot, Integer x, Integer y)-
Methods inherited from class net.minecraft.world.inventory.Slot
allowModification, getContainerSlot, getNoItemIcon, getSlotIndex, isActive, isFake, isHighlightable, isSameInventory, onQuickCraft, onTake, safeInsert, safeInsert, safeTake, setBackground, setByPlayer, setByPlayer -
Methods inherited from class hiiragi283.core.common.inventory.HTContainerItemSlot
getItem, getMaxStackSize -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
HTContainerItemSlot
HTContainerItemSlot(HTItemSlot slot, Integer x, Integer y, Consumer<ItemStack> stackSetter, Function2<HTItemResourceType, HTStorageAccess, Boolean> manualFilter, HTContainerItemSlot.Type slotType)
-
HTContainerItemSlot
HTContainerItemSlot(HTItemSlot.Basic slot, Integer x, Integer y, HTContainerItemSlot.Type slotType)
-
-
Method Detail
-
getSlot
final HTItemSlot getSlot()
-
getSlotType
final HTContainerItemSlot.Type getSlotType()
-
updateCount
final Unit updateCount(Integer count)
-
getItem
ItemStack getItem()
-
setChanged
Unit setChanged()
-
getMaxStackSize
Integer getMaxStackSize()
-
getMaxStackSize
Integer getMaxStackSize(ItemStack stack)
-
input
final static HTContainerItemSlot input(HTItemSlot.Basic slot, Integer x, Integer y)
-
output
final static HTContainerItemSlot output(HTItemSlot.Basic slot, Integer x, Integer y)
-
both
final static HTContainerItemSlot both(HTItemSlot.Basic slot, Integer x, Integer y)
-
-
-
-