Package net.minecraft.screen
Class ScreenHandler
java.lang.Object
net.minecraft.screen.ScreenHandler
- Direct Known Subclasses:
AnvilScreenHandler,BeaconScreenHandler,BrewingScreenHandler,ChestScreenHandler,class_416,class_4535,CraftingScreenHandler,EnchantingScreenHandler,FurnaceScreenHandler,Generic3x3ScreenHandler,HopperScreenHandler,HorseScreenHandler,PlayerScreenHandler,VillagerScreenHandler
- Mappings:
Namespace Name official aibintermediary net/minecraft/class_1002named net/minecraft/screen/ScreenHandler
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddListener(ScreenHandlerListener listener) protected Slotstatic intcalculateComparatorOutput(BlockEntity entity) static intcalculateComparatorOutput(Inventory inventory) static voidcalculateStackSize(Set slots, int rmode, ItemStack stack, int stackSize) booleancanInsertIntoSlot(Slot slot) booleancanInsertIntoSlot(ItemStack stack, Slot slot) static booleancanInsertItemIntoSlot(Slot slot, ItemStack stack, boolean bool) abstract booleancanUse(PlayerEntity player) voidclose(PlayerEntity player) protected voidshortgetNextActionId(PlayerInventory playerInventory) getSlot(int index) protected booleaninsertItem(ItemStack stack, int startIndex, int endIndex, boolean fromLast) booleanisNotRestricted(PlayerEntity player) method_3255(Inventory inventory, int int2) booleanonButtonClick(PlayerEntity player, int id) voidonContentChanged(Inventory inventory) protected voidonSlotClick(int slotId, int clickData, boolean bool, PlayerEntity player) onSlotClick(int slotId, int clickData, int actionType, PlayerEntity player) static intpackClickData(int buttonId, int quickCraftStage) voidremoveListener(ScreenHandlerListener listener) voidSends updates to listeners if any properties or slot stacks have changed.voidsetPlayerRestriction(PlayerEntity player, boolean unrestricted) voidsetProperty(int id, int value) voidsetStackInSlot(int slot, ItemStack stack) static booleanshouldQuickCraftContinue(int int2, PlayerEntity player) transferSlot(PlayerEntity player, int invSlot) static intunpackButtonId(int clickData) static intunpackQuickCraftStage(int clickData) voidupdateSlotStacks(ItemStack[] stacks)
-
Field Details
-
trackedStacks
- Mappings:
Namespace Name Mixin selector official bLaib;b:Ljava/util/List;intermediary field_4086Lnet/minecraft/class_1002;field_4086:Ljava/util/List;named trackedStacksLnet/minecraft/screen/ScreenHandler;trackedStacks:Ljava/util/List;
-
slots
- Mappings:
Namespace Name Mixin selector official cLaib;c:Ljava/util/List;intermediary field_4087Lnet/minecraft/class_1002;field_4087:Ljava/util/List;named slotsLnet/minecraft/screen/ScreenHandler;slots:Ljava/util/List;
-
syncId
public int syncId- Mappings:
Namespace Name Mixin selector official dLaib;d:Iintermediary field_4088Lnet/minecraft/class_1002;field_4088:Inamed syncIdLnet/minecraft/screen/ScreenHandler;syncId:I
-
actionId
- Mappings:
Namespace Name Mixin selector official aLaib;a:Sintermediary field_4090Lnet/minecraft/class_1002;field_4090:Snamed actionIdLnet/minecraft/screen/ScreenHandler;actionId:S
-
quickCraftStage
private int quickCraftStage- Mappings:
Namespace Name Mixin selector official fLaib;f:Iintermediary field_6159Lnet/minecraft/class_1002;field_6159:Inamed quickCraftStageLnet/minecraft/screen/ScreenHandler;quickCraftStage:I
-
quickCraftButton
private int quickCraftButton- Mappings:
Namespace Name Mixin selector official gLaib;g:Iintermediary field_6160Lnet/minecraft/class_1002;field_6160:Inamed quickCraftButtonLnet/minecraft/screen/ScreenHandler;quickCraftButton:I
-
quickCraftSlots
- Mappings:
Namespace Name Mixin selector official hLaib;h:Ljava/util/Set;intermediary field_6161Lnet/minecraft/class_1002;field_6161:Ljava/util/Set;named quickCraftSlotsLnet/minecraft/screen/ScreenHandler;quickCraftSlots:Ljava/util/Set;
-
listeners
- Mappings:
Namespace Name Mixin selector official eLaib;e:Ljava/util/List;intermediary field_4089Lnet/minecraft/class_1002;field_4089:Ljava/util/List;named listenersLnet/minecraft/screen/ScreenHandler;listeners:Ljava/util/List;
-
restrictedPlayers
- Mappings:
Namespace Name Mixin selector official iLaib;i:Ljava/util/Set;intermediary field_4091Lnet/minecraft/class_1002;field_4091:Ljava/util/Set;named restrictedPlayersLnet/minecraft/screen/ScreenHandler;restrictedPlayers:Ljava/util/Set;
-
-
Constructor Details
-
ScreenHandler
public ScreenHandler()
-
-
Method Details
-
addSlot
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lajk;)Lajk;intermediary method_3261Lnet/minecraft/class_1002;method_3261(Lnet/minecraft/class_1026;)Lnet/minecraft/class_1026;named addSlotLnet/minecraft/screen/ScreenHandler;addSlot(Lnet/minecraft/inventory/slot/Slot;)Lnet/minecraft/inventory/slot/Slot;
-
addListener
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lail;)Vintermediary method_3260Lnet/minecraft/class_1002;method_3260(Lnet/minecraft/class_1006;)Vnamed addListenerLnet/minecraft/screen/ScreenHandler;addListener(Lnet/minecraft/screen/ScreenHandlerListener;)V
-
removeListener
- Mappings:
Namespace Name Mixin selector official bLaib;b(Lail;)Vintermediary method_4589Lnet/minecraft/class_1002;method_4589(Lnet/minecraft/class_1006;)Vnamed removeListenerLnet/minecraft/screen/ScreenHandler;removeListener(Lnet/minecraft/screen/ScreenHandlerListener;)V
-
getStacks
- Mappings:
Namespace Name Mixin selector official aLaib;a()Ljava/util/List;intermediary method_3250Lnet/minecraft/class_1002;method_3250()Ljava/util/List;named getStacksLnet/minecraft/screen/ScreenHandler;getStacks()Ljava/util/List;
-
sendContentUpdates
public void sendContentUpdates()Sends updates to listeners if any properties or slot stacks have changed.- Mappings:
Namespace Name Mixin selector official bLaib;b()Vintermediary method_3264Lnet/minecraft/class_1002;method_3264()Vnamed sendContentUpdatesLnet/minecraft/screen/ScreenHandler;sendContentUpdates()V
-
onButtonClick
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lahd;I)Zintermediary method_3258Lnet/minecraft/class_1002;method_3258(Lnet/minecraft/class_988;I)Znamed onButtonClickLnet/minecraft/screen/ScreenHandler;onButtonClick(Lnet/minecraft/entity/player/PlayerEntity;I)Z
-
method_3255
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lvq;I)Lajk;intermediary method_3255Lnet/minecraft/class_1002;method_3255(Lnet/minecraft/class_849;I)Lnet/minecraft/class_1026;named method_3255Lnet/minecraft/screen/ScreenHandler;method_3255(Lnet/minecraft/inventory/Inventory;I)Lnet/minecraft/inventory/slot/Slot;
-
getSlot
- Mappings:
Namespace Name Mixin selector official aLaib;a(I)Lajk;intermediary method_3251Lnet/minecraft/class_1002;method_3251(I)Lnet/minecraft/class_1026;named getSlotLnet/minecraft/screen/ScreenHandler;getSlot(I)Lnet/minecraft/inventory/slot/Slot;
-
transferSlot
- Mappings:
Namespace Name Mixin selector official bLaib;b(Lahd;I)Lamj;intermediary method_3265Lnet/minecraft/class_1002;method_3265(Lnet/minecraft/class_988;I)Lnet/minecraft/class_1071;named transferSlotLnet/minecraft/screen/ScreenHandler;transferSlot(Lnet/minecraft/entity/player/PlayerEntity;I)Lnet/minecraft/item/ItemStack;
-
onSlotClick
- Mappings:
Namespace Name Mixin selector official aLaib;a(IIILahd;)Lamj;intermediary method_3252Lnet/minecraft/class_1002;method_3252(IIILnet/minecraft/class_988;)Lnet/minecraft/class_1071;named onSlotClickLnet/minecraft/screen/ScreenHandler;onSlotClick(IIILnet/minecraft/entity/player/PlayerEntity;)Lnet/minecraft/item/ItemStack;
-
canInsertIntoSlot
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lamj;Lajk;)Zintermediary method_5449Lnet/minecraft/class_1002;method_5449(Lnet/minecraft/class_1071;Lnet/minecraft/class_1026;)Znamed canInsertIntoSlotLnet/minecraft/screen/ScreenHandler;canInsertIntoSlot(Lnet/minecraft/item/ItemStack;Lnet/minecraft/inventory/slot/Slot;)Z
-
onSlotClick
- Mappings:
Namespace Name Mixin selector official aLaib;a(IIZLahd;)Vintermediary method_3267Lnet/minecraft/class_1002;method_3267(IIZLnet/minecraft/class_988;)Vnamed onSlotClickLnet/minecraft/screen/ScreenHandler;onSlotClick(IIZLnet/minecraft/entity/player/PlayerEntity;)V
-
close
- Mappings:
Namespace Name Mixin selector official bLaib;b(Lahd;)Vintermediary method_3257Lnet/minecraft/class_1002;method_3257(Lnet/minecraft/class_988;)Vnamed closeLnet/minecraft/screen/ScreenHandler;close(Lnet/minecraft/entity/player/PlayerEntity;)V
-
onContentChanged
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lvq;)Vintermediary method_3254Lnet/minecraft/class_1002;method_3254(Lnet/minecraft/class_849;)Vnamed onContentChangedLnet/minecraft/screen/ScreenHandler;onContentChanged(Lnet/minecraft/inventory/Inventory;)V
-
setStackInSlot
- Mappings:
Namespace Name Mixin selector official aLaib;a(ILamj;)Vintermediary method_3253Lnet/minecraft/class_1002;method_3253(ILnet/minecraft/class_1071;)Vnamed setStackInSlotLnet/minecraft/screen/ScreenHandler;setStackInSlot(ILnet/minecraft/item/ItemStack;)V
-
updateSlotStacks
- Mappings:
Namespace Name Mixin selector official aLaib;a([Lamj;)Vintermediary method_3263Lnet/minecraft/class_1002;method_3263([Lnet/minecraft/class_1071;)Vnamed updateSlotStacksLnet/minecraft/screen/ScreenHandler;updateSlotStacks([Lnet/minecraft/item/ItemStack;)V
-
setProperty
- Mappings:
Namespace Name Mixin selector official bLaib;b(II)Vintermediary method_3266Lnet/minecraft/class_1002;method_3266(II)Vnamed setPropertyLnet/minecraft/screen/ScreenHandler;setProperty(II)V
-
getNextActionId
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lahb;)Sintermediary method_3256Lnet/minecraft/class_1002;method_3256(Lnet/minecraft/class_987;)Snamed getNextActionIdLnet/minecraft/screen/ScreenHandler;getNextActionId(Lnet/minecraft/entity/player/PlayerInventory;)S
-
isNotRestricted
- Mappings:
Namespace Name Mixin selector official cLaib;c(Lahd;)Zintermediary method_3268Lnet/minecraft/class_1002;method_3268(Lnet/minecraft/class_988;)Znamed isNotRestrictedLnet/minecraft/screen/ScreenHandler;isNotRestricted(Lnet/minecraft/entity/player/PlayerEntity;)Z
-
setPlayerRestriction
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lahd;Z)Vintermediary method_3259Lnet/minecraft/class_1002;method_3259(Lnet/minecraft/class_988;Z)Vnamed setPlayerRestrictionLnet/minecraft/screen/ScreenHandler;setPlayerRestriction(Lnet/minecraft/entity/player/PlayerEntity;Z)V
-
canUse
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lahd;)Zintermediary method_3269Lnet/minecraft/class_1002;method_3269(Lnet/minecraft/class_988;)Znamed canUseLnet/minecraft/screen/ScreenHandler;canUse(Lnet/minecraft/entity/player/PlayerEntity;)Z
-
insertItem
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lamj;IIZ)Zintermediary method_3262Lnet/minecraft/class_1002;method_3262(Lnet/minecraft/class_1071;IIZ)Znamed insertItemLnet/minecraft/screen/ScreenHandler;insertItem(Lnet/minecraft/item/ItemStack;IIZ)Z
-
unpackQuickCraftStage
public static int unpackQuickCraftStage(int clickData) - Mappings:
Namespace Name Mixin selector official bLaib;b(I)Iintermediary method_5450Lnet/minecraft/class_1002;method_5450(I)Inamed unpackQuickCraftStageLnet/minecraft/screen/ScreenHandler;unpackQuickCraftStage(I)I
-
unpackButtonId
public static int unpackButtonId(int clickData) - Mappings:
Namespace Name Mixin selector official cLaib;c(I)Iintermediary method_5453Lnet/minecraft/class_1002;method_5453(I)Inamed unpackButtonIdLnet/minecraft/screen/ScreenHandler;unpackButtonId(I)I
-
packClickData
- Mappings:
Namespace Name Mixin selector official dLaib;d(II)Iintermediary method_5456Lnet/minecraft/class_1002;method_5456(II)Inamed packClickDataLnet/minecraft/screen/ScreenHandler;packClickData(II)I
-
shouldQuickCraftContinue
- Mappings:
Namespace Name Mixin selector official aLaib;a(ILahd;)Zintermediary method_11255Lnet/minecraft/class_1002;method_11255(ILnet/minecraft/class_988;)Znamed shouldQuickCraftContinueLnet/minecraft/screen/ScreenHandler;shouldQuickCraftContinue(ILnet/minecraft/entity/player/PlayerEntity;)Z
-
endQuickCraft
protected void endQuickCraft()- Mappings:
Namespace Name Mixin selector official dLaib;d()Vintermediary method_5454Lnet/minecraft/class_1002;method_5454()Vnamed endQuickCraftLnet/minecraft/screen/ScreenHandler;endQuickCraft()V
-
canInsertItemIntoSlot
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lajk;Lamj;Z)Zintermediary method_5448Lnet/minecraft/class_1002;method_5448(Lnet/minecraft/class_1026;Lnet/minecraft/class_1071;Z)Znamed canInsertItemIntoSlotLnet/minecraft/screen/ScreenHandler;canInsertItemIntoSlot(Lnet/minecraft/inventory/slot/Slot;Lnet/minecraft/item/ItemStack;Z)Z
-
calculateStackSize
- Mappings:
Namespace Name Mixin selector official aLaib;a(Ljava/util/Set;ILamj;I)Vintermediary method_5447Lnet/minecraft/class_1002;method_5447(Ljava/util/Set;ILnet/minecraft/class_1071;I)Vnamed calculateStackSizeLnet/minecraft/screen/ScreenHandler;calculateStackSize(Ljava/util/Set;ILnet/minecraft/item/ItemStack;I)V
-
canInsertIntoSlot
- Mappings:
Namespace Name Mixin selector official bLaib;b(Lajk;)Zintermediary method_5452Lnet/minecraft/class_1002;method_5452(Lnet/minecraft/class_1026;)Znamed canInsertIntoSlotLnet/minecraft/screen/ScreenHandler;canInsertIntoSlot(Lnet/minecraft/inventory/slot/Slot;)Z
-
calculateComparatorOutput
- Mappings:
Namespace Name Mixin selector official aLaib;a(Lbcm;)Iintermediary method_11256Lnet/minecraft/class_1002;method_11256(Lnet/minecraft/class_226;)Inamed calculateComparatorOutputLnet/minecraft/screen/ScreenHandler;calculateComparatorOutput(Lnet/minecraft/block/entity/BlockEntity;)I
-
calculateComparatorOutput
- Mappings:
Namespace Name Mixin selector official bLaib;b(Lvq;)Iintermediary method_5451Lnet/minecraft/class_1002;method_5451(Lnet/minecraft/class_849;)Inamed calculateComparatorOutputLnet/minecraft/screen/ScreenHandler;calculateComparatorOutput(Lnet/minecraft/inventory/Inventory;)I
-