Package net.minecraft.block
Class ComposterBlock.ComposterInventory
java.lang.Object
net.minecraft.inventory.SimpleInventory
net.minecraft.block.ComposterBlock.ComposterInventory
- All Implemented Interfaces:
Inventory,SidedInventory,RecipeInputProvider,Clearable
- Enclosing class:
ComposterBlock
private static class ComposterBlock.ComposterInventory
extends SimpleInventory
implements SidedInventory
- Mappings:
Namespace Name named net/minecraft/block/ComposterBlock$ComposterInventoryintermediary net/minecraft/class_3962$class_3963official dhj$b
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanprivate final BlockPosprivate final BlockStateprivate final WorldAccessFields inherited from interface net.minecraft.inventory.Inventory
DEFAULT_MAX_INTERACTION_RANGE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanExtract(int slot, ItemStack stack, Direction dir) Returns whether the given stack can be removed from this inventory at the specified slot position from the given direction.booleanReturns whether the given stack can be inserted into this inventory at the specified slot position from the given direction.int[]getAvailableSlots(Direction side) Returns the available slot positions that are reachable from a given side.intReturns the maximum number of items a stack can contain when placed inside this inventory.voidMarks the inventory as modified.Methods inherited from class net.minecraft.inventory.SimpleInventory
addListener, addStack, canInsert, canPlayerUse, clear, clearToList, getHeldStacks, getStack, isEmpty, provideRecipeInputs, readNbtList, removeItem, removeListener, removeStack, removeStack, setStack, size, toNbtList, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.inventory.Inventory
canPlayerUse, canTransferTo, containsAny, containsAny, count, getMaxCount, getStack, isEmpty, isValid, onClose, onOpen, removeStack, removeStack, setStack, size
-
Field Details
-
state
- Mappings:
Namespace Name Mixin selector named stateLnet/minecraft/block/ComposterBlock$ComposterInventory;state:Lnet/minecraft/block/BlockState;intermediary field_17569Lnet/minecraft/class_3962$class_3963;field_17569:Lnet/minecraft/class_2680;official bLdhj$b;b:Ldtc;
-
world
- Mappings:
Namespace Name Mixin selector named worldLnet/minecraft/block/ComposterBlock$ComposterInventory;world:Lnet/minecraft/world/WorldAccess;intermediary field_17570Lnet/minecraft/class_3962$class_3963;field_17570:Lnet/minecraft/class_1936;official cLdhj$b;c:Ldcx;
-
pos
- Mappings:
Namespace Name Mixin selector named posLnet/minecraft/block/ComposterBlock$ComposterInventory;pos:Lnet/minecraft/util/math/BlockPos;intermediary field_17571Lnet/minecraft/class_3962$class_3963;field_17571:Lnet/minecraft/class_2338;official dLdhj$b;d:Ljd;
-
dirty
private boolean dirty- Mappings:
Namespace Name Mixin selector named dirtyLnet/minecraft/block/ComposterBlock$ComposterInventory;dirty:Zintermediary field_17572Lnet/minecraft/class_3962$class_3963;field_17572:Zofficial eLdhj$b;e:Z
-
-
Constructor Details
-
ComposterInventory
- Mappings:
Namespace Name Mixin selector named <init>Lnet/minecraft/block/ComposterBlock$ComposterInventory;<init>(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/WorldAccess;Lnet/minecraft/util/math/BlockPos;)Vintermediary <init>Lnet/minecraft/class_3962$class_3963;<init>(Lnet/minecraft/class_2680;Lnet/minecraft/class_1936;Lnet/minecraft/class_2338;)Vofficial <init>Ldhj$b;<init>(Ldtc;Ldcx;Ljd;)V
-
-
Method Details
-
getMaxCountPerStack
public int getMaxCountPerStack()Returns the maximum number of items a stack can contain when placed inside this inventory.No slots may have more than this number of items. It is effectively the stacking limit for this inventory's slots.
- Specified by:
getMaxCountPerStackin interfaceInventory- Returns:
- the maximum number of items a stack can contain when placed inside this inventory
- Mappings:
Namespace Name Mixin selector named getMaxCountPerStackLnet/minecraft/inventory/Inventory;getMaxCountPerStack()Iintermediary method_5444Lnet/minecraft/class_1263;method_5444()Iofficial al_Lbqk;al_()I
-
getAvailableSlots
Returns the available slot positions that are reachable from a given side.- Specified by:
getAvailableSlotsin interfaceSidedInventory- Returns:
- the available slot positions that are reachable from a given side
- Mappings:
Namespace Name Mixin selector named getAvailableSlotsLnet/minecraft/inventory/SidedInventory;getAvailableSlots(Lnet/minecraft/util/math/Direction;)[Iintermediary method_5494Lnet/minecraft/class_1278;method_5494(Lnet/minecraft/class_2350;)[Iofficial aLbrd;a(Lji;)[I
-
canInsert
Returns whether the given stack can be inserted into this inventory at the specified slot position from the given direction.- Specified by:
canInsertin interfaceSidedInventory- Returns:
- whether the given stack can be inserted into this inventory at the specified slot position from the given direction
- Mappings:
Namespace Name Mixin selector named canInsertLnet/minecraft/inventory/SidedInventory;canInsert(ILnet/minecraft/item/ItemStack;Lnet/minecraft/util/math/Direction;)Zintermediary method_5492Lnet/minecraft/class_1278;method_5492(ILnet/minecraft/class_1799;Lnet/minecraft/class_2350;)Zofficial aLbrd;a(ILcuq;Lji;)Z
-
canExtract
Returns whether the given stack can be removed from this inventory at the specified slot position from the given direction.- Specified by:
canExtractin interfaceSidedInventory- Returns:
- whether the given stack can be removed from this inventory at the specified slot position from the given direction
- Mappings:
Namespace Name Mixin selector named canExtractLnet/minecraft/inventory/SidedInventory;canExtract(ILnet/minecraft/item/ItemStack;Lnet/minecraft/util/math/Direction;)Zintermediary method_5493Lnet/minecraft/class_1278;method_5493(ILnet/minecraft/class_1799;Lnet/minecraft/class_2350;)Zofficial bLbrd;b(ILcuq;Lji;)Z
-
markDirty
public void markDirty()Marks the inventory as modified. Implementations should call this method every time the inventory is changed in any way.- Specified by:
markDirtyin interfaceInventory- Overrides:
markDirtyin classSimpleInventory- See Also:
- API Note:
- Implementations should mark the inventory for synchronization or
saving in this method. Since this is called frequently, it is not recommended to
synchronize or save the inventory directly in this method. If this inventory is
implemented in a block entity, then it should always call
super.markDirty();to ensure the block entity gets saved. - Mappings:
Namespace Name Mixin selector named markDirtyLnet/minecraft/inventory/Inventory;markDirty()Vintermediary method_5431Lnet/minecraft/class_1263;method_5431()Vofficial eLbqk;e()V
-