Class ScreenHandler

java.lang.Object
net.minecraft.screen.ScreenHandler
Direct Known Subclasses:
AnvilScreenHandler, BeaconScreenHandler, BrewingScreenHandler, ChestScreenHandler, CraftingScreenHandler, CreativeInventoryScreen.CreativeScreenHandler, EnchantingScreenHandler, FurnaceScreenHandler, Generic3x3ScreenHandler, HopperScreenHandler, HorseScreenHandler, PlayerScreenHandler, VillagerScreenHandler

public abstract class ScreenHandler
extends Object
Mappings:
Namespace Name
official xi
intermediary net/minecraft/class_1983
named net/minecraft/screen/ScreenHandler
  • Field Details

    • trackedStacks

      public List<ItemStack> trackedStacks
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b:Ljava/util/List;
      intermediary field_8439 Lnet/minecraft/class_1983;field_8439:Ljava/util/List;
      named trackedStacks Lnet/minecraft/screen/ScreenHandler;trackedStacks:Ljava/util/List;
    • slots

      public List<Slot> slots
      Mappings:
      Namespace Name Mixin selector
      official c Lxi;c:Ljava/util/List;
      intermediary field_8440 Lnet/minecraft/class_1983;field_8440:Ljava/util/List;
      named slots Lnet/minecraft/screen/ScreenHandler;slots:Ljava/util/List;
    • syncId

      public int syncId
      Mappings:
      Namespace Name Mixin selector
      official d Lxi;d:I
      intermediary field_8441 Lnet/minecraft/class_1983;field_8441:I
      named syncId Lnet/minecraft/screen/ScreenHandler;syncId:I
    • actionId

      @Environment(CLIENT) private short actionId
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a:S
      intermediary field_8438 Lnet/minecraft/class_1983;field_8438:S
      named actionId Lnet/minecraft/screen/ScreenHandler;actionId:S
    • quickCraftStage

      private int quickCraftStage
      Mappings:
      Namespace Name Mixin selector
      official f Lxi;f:I
      intermediary field_8443 Lnet/minecraft/class_1983;field_8443:I
      named quickCraftStage Lnet/minecraft/screen/ScreenHandler;quickCraftStage:I
    • quickCraftButton

      private int quickCraftButton
      Mappings:
      Namespace Name Mixin selector
      official g Lxi;g:I
      intermediary field_8444 Lnet/minecraft/class_1983;field_8444:I
      named quickCraftButton Lnet/minecraft/screen/ScreenHandler;quickCraftButton:I
    • quickCraftSlots

      private final Set<Slot> quickCraftSlots
      Mappings:
      Namespace Name Mixin selector
      official h Lxi;h:Ljava/util/Set;
      intermediary field_8445 Lnet/minecraft/class_1983;field_8445:Ljava/util/Set;
      named quickCraftSlots Lnet/minecraft/screen/ScreenHandler;quickCraftSlots:Ljava/util/Set;
    • listeners

      protected List<ScreenHandlerListener> listeners
      Mappings:
      Namespace Name Mixin selector
      official e Lxi;e:Ljava/util/List;
      intermediary field_8442 Lnet/minecraft/class_1983;field_8442:Ljava/util/List;
      named listeners Lnet/minecraft/screen/ScreenHandler;listeners:Ljava/util/List;
    • restrictedPlayers

      private Set<PlayerEntity> restrictedPlayers
      Mappings:
      Namespace Name Mixin selector
      official i Lxi;i:Ljava/util/Set;
      intermediary field_8446 Lnet/minecraft/class_1983;field_8446:Ljava/util/Set;
      named restrictedPlayers Lnet/minecraft/screen/ScreenHandler;restrictedPlayers:Ljava/util/Set;
  • Constructor Details

    • ScreenHandler

      public ScreenHandler()
  • Method Details

    • addSlot

      protected Slot addSlot​(Slot slot)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lyg;)Lyg;
      intermediary method_8108 Lnet/minecraft/class_1983;method_8108(Lnet/minecraft/class_2010;)Lnet/minecraft/class_2010;
      named addSlot Lnet/minecraft/screen/ScreenHandler;addSlot(Lnet/minecraft/inventory/slot/Slot;)Lnet/minecraft/inventory/slot/Slot;
    • addListener

      public void addListener​(ScreenHandlerListener listener)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lxn;)V
      intermediary method_8107 Lnet/minecraft/class_1983;method_8107(Lnet/minecraft/class_1991;)V
      named addListener Lnet/minecraft/screen/ScreenHandler;addListener(Lnet/minecraft/screen/ScreenHandlerListener;)V
    • removeListener

      @Environment(CLIENT) public void removeListener​(ScreenHandlerListener listener)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(Lxn;)V
      intermediary method_8119 Lnet/minecraft/class_1983;method_8119(Lnet/minecraft/class_1991;)V
      named removeListener Lnet/minecraft/screen/ScreenHandler;removeListener(Lnet/minecraft/screen/ScreenHandlerListener;)V
    • getStacks

      public List<ItemStack> getStacks()
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a()Ljava/util/List;
      intermediary method_8093 Lnet/minecraft/class_1983;method_8093()Ljava/util/List;
      named getStacks Lnet/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 b Lxi;b()V
      intermediary method_8113 Lnet/minecraft/class_1983;method_8113()V
      named sendContentUpdates Lnet/minecraft/screen/ScreenHandler;sendContentUpdates()V
    • onButtonClick

      public boolean onButtonClick​(PlayerEntity player, int id)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lwn;I)Z
      intermediary method_8105 Lnet/minecraft/class_1983;method_8105(Lnet/minecraft/class_1963;I)Z
      named onButtonClick Lnet/minecraft/screen/ScreenHandler;onButtonClick(Lnet/minecraft/entity/player/PlayerEntity;I)Z
    • method_8102

      public Slot method_8102​(Inventory inventory, int int2)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Log;I)Lyg;
      intermediary method_8102 Lnet/minecraft/class_1983;method_8102(Lnet/minecraft/class_1718;I)Lnet/minecraft/class_2010;
      named method_8102 Lnet/minecraft/screen/ScreenHandler;method_8102(Lnet/minecraft/inventory/Inventory;I)Lnet/minecraft/inventory/slot/Slot;
    • getSlot

      public Slot getSlot​(int index)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(I)Lyg;
      intermediary method_8094 Lnet/minecraft/class_1983;method_8094(I)Lnet/minecraft/class_2010;
      named getSlot Lnet/minecraft/screen/ScreenHandler;getSlot(I)Lnet/minecraft/inventory/slot/Slot;
    • transferSlot

      public ItemStack transferSlot​(PlayerEntity player, int invSlot)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(Lwn;I)Lzx;
      intermediary method_8118 Lnet/minecraft/class_1983;method_8118(Lnet/minecraft/class_1963;I)Lnet/minecraft/class_2056;
      named transferSlot Lnet/minecraft/screen/ScreenHandler;transferSlot(Lnet/minecraft/entity/player/PlayerEntity;I)Lnet/minecraft/item/ItemStack;
    • onSlotClick

      public ItemStack onSlotClick​(int slotId, int clickData, int actionType, PlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(IIILwn;)Lzx;
      intermediary method_8095 Lnet/minecraft/class_1983;method_8095(IIILnet/minecraft/class_1963;)Lnet/minecraft/class_2056;
      named onSlotClick Lnet/minecraft/screen/ScreenHandler;onSlotClick(IIILnet/minecraft/entity/player/PlayerEntity;)Lnet/minecraft/item/ItemStack;
    • canInsertIntoSlot

      public boolean canInsertIntoSlot​(ItemStack stack, Slot slot)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lzx;Lyg;)Z
      intermediary method_8111 Lnet/minecraft/class_1983;method_8111(Lnet/minecraft/class_2056;Lnet/minecraft/class_2010;)Z
      named canInsertIntoSlot Lnet/minecraft/screen/ScreenHandler;canInsertIntoSlot(Lnet/minecraft/item/ItemStack;Lnet/minecraft/inventory/slot/Slot;)Z
    • method_8096

      protected void method_8096​(int int2, int int3, boolean bool, PlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(IIZLwn;)V
      intermediary method_8096 Lnet/minecraft/class_1983;method_8096(IIZLnet/minecraft/class_1963;)V
      named method_8096 Lnet/minecraft/screen/ScreenHandler;method_8096(IIZLnet/minecraft/entity/player/PlayerEntity;)V
    • close

      public void close​(PlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(Lwn;)V
      intermediary method_8117 Lnet/minecraft/class_1983;method_8117(Lnet/minecraft/class_1963;)V
      named close Lnet/minecraft/screen/ScreenHandler;close(Lnet/minecraft/entity/player/PlayerEntity;)V
    • onContentChanged

      public void onContentChanged​(Inventory inventory)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Log;)V
      intermediary method_8101 Lnet/minecraft/class_1983;method_8101(Lnet/minecraft/class_1718;)V
      named onContentChanged Lnet/minecraft/screen/ScreenHandler;onContentChanged(Lnet/minecraft/inventory/Inventory;)V
    • setStackInSlot

      public void setStackInSlot​(int slot, ItemStack stack)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(ILzx;)V
      intermediary method_8098 Lnet/minecraft/class_1983;method_8098(ILnet/minecraft/class_2056;)V
      named setStackInSlot Lnet/minecraft/screen/ScreenHandler;setStackInSlot(ILnet/minecraft/item/ItemStack;)V
    • updateSlotStacks

      @Environment(CLIENT) public void updateSlotStacks​(ItemStack[] stacks)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a([Lzx;)V
      intermediary method_8112 Lnet/minecraft/class_1983;method_8112([Lnet/minecraft/class_2056;)V
      named updateSlotStacks Lnet/minecraft/screen/ScreenHandler;updateSlotStacks([Lnet/minecraft/item/ItemStack;)V
    • setProperty

      @Environment(CLIENT) public void setProperty​(int id, int value)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(II)V
      intermediary method_8115 Lnet/minecraft/class_1983;method_8115(II)V
      named setProperty Lnet/minecraft/screen/ScreenHandler;setProperty(II)V
    • getNextActionId

      @Environment(CLIENT) public short getNextActionId​(PlayerInventory playerInventory)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lwm;)S
      intermediary method_8103 Lnet/minecraft/class_1983;method_8103(Lnet/minecraft/class_1962;)S
      named getNextActionId Lnet/minecraft/screen/ScreenHandler;getNextActionId(Lnet/minecraft/entity/player/PlayerInventory;)S
    • isNotRestricted

      public boolean isNotRestricted​(PlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official c Lxi;c(Lwn;)Z
      intermediary method_8122 Lnet/minecraft/class_1983;method_8122(Lnet/minecraft/class_1963;)Z
      named isNotRestricted Lnet/minecraft/screen/ScreenHandler;isNotRestricted(Lnet/minecraft/entity/player/PlayerEntity;)Z
    • setPlayerRestriction

      public void setPlayerRestriction​(PlayerEntity player, boolean unrestricted)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lwn;Z)V
      intermediary method_8106 Lnet/minecraft/class_1983;method_8106(Lnet/minecraft/class_1963;Z)V
      named setPlayerRestriction Lnet/minecraft/screen/ScreenHandler;setPlayerRestriction(Lnet/minecraft/entity/player/PlayerEntity;Z)V
    • canUse

      public abstract boolean canUse​(PlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lwn;)Z
      intermediary method_8104 Lnet/minecraft/class_1983;method_8104(Lnet/minecraft/class_1963;)Z
      named canUse Lnet/minecraft/screen/ScreenHandler;canUse(Lnet/minecraft/entity/player/PlayerEntity;)Z
    • insertItem

      protected boolean insertItem​(ItemStack stack, int startIndex, int endIndex, boolean fromLast)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lzx;IIZ)Z
      intermediary method_8110 Lnet/minecraft/class_1983;method_8110(Lnet/minecraft/class_2056;IIZ)Z
      named insertItem Lnet/minecraft/screen/ScreenHandler;insertItem(Lnet/minecraft/item/ItemStack;IIZ)Z
    • unpackQuickCraftStage

      public static int unpackQuickCraftStage​(int clickData)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(I)I
      intermediary method_8114 Lnet/minecraft/class_1983;method_8114(I)I
      named unpackQuickCraftStage Lnet/minecraft/screen/ScreenHandler;unpackQuickCraftStage(I)I
    • unpackButtonId

      public static int unpackButtonId​(int clickData)
      Mappings:
      Namespace Name Mixin selector
      official c Lxi;c(I)I
      intermediary method_8121 Lnet/minecraft/class_1983;method_8121(I)I
      named unpackButtonId Lnet/minecraft/screen/ScreenHandler;unpackButtonId(I)I
    • packClickData

      @Environment(CLIENT) public static int packClickData​(int buttonId, int quickCraftStage)
      Mappings:
      Namespace Name Mixin selector
      official d Lxi;d(II)I
      intermediary method_8124 Lnet/minecraft/class_1983;method_8124(II)I
      named packClickData Lnet/minecraft/screen/ScreenHandler;packClickData(II)I
    • shouldQuickCraftContinue

      public static boolean shouldQuickCraftContinue​(int int2, PlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(ILwn;)Z
      intermediary method_8097 Lnet/minecraft/class_1983;method_8097(ILnet/minecraft/class_1963;)Z
      named shouldQuickCraftContinue Lnet/minecraft/screen/ScreenHandler;shouldQuickCraftContinue(ILnet/minecraft/entity/player/PlayerEntity;)Z
    • endQuickCraft

      protected void endQuickCraft()
      Mappings:
      Namespace Name Mixin selector
      official d Lxi;d()V
      intermediary method_8123 Lnet/minecraft/class_1983;method_8123()V
      named endQuickCraft Lnet/minecraft/screen/ScreenHandler;endQuickCraft()V
    • canInsertItemIntoSlot

      public static boolean canInsertItemIntoSlot​(Slot slot, ItemStack stack, boolean bool)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lyg;Lzx;Z)Z
      intermediary method_8109 Lnet/minecraft/class_1983;method_8109(Lnet/minecraft/class_2010;Lnet/minecraft/class_2056;Z)Z
      named canInsertItemIntoSlot Lnet/minecraft/screen/ScreenHandler;canInsertItemIntoSlot(Lnet/minecraft/inventory/slot/Slot;Lnet/minecraft/item/ItemStack;Z)Z
    • calculateStackSize

      public static void calculateStackSize​(Set<Slot> slots, int rmode, ItemStack stack, int stackSize)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Ljava/util/Set;ILzx;I)V
      intermediary method_8100 Lnet/minecraft/class_1983;method_8100(Ljava/util/Set;ILnet/minecraft/class_2056;I)V
      named calculateStackSize Lnet/minecraft/screen/ScreenHandler;calculateStackSize(Ljava/util/Set;ILnet/minecraft/item/ItemStack;I)V
    • canInsertIntoSlot

      public boolean canInsertIntoSlot​(Slot slot)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(Lyg;)Z
      intermediary method_8120 Lnet/minecraft/class_1983;method_8120(Lnet/minecraft/class_2010;)Z
      named canInsertIntoSlot Lnet/minecraft/screen/ScreenHandler;canInsertIntoSlot(Lnet/minecraft/inventory/slot/Slot;)Z
    • calculateComparatorOutput

      public static int calculateComparatorOutput​(BlockEntity entity)
      Mappings:
      Namespace Name Mixin selector
      official a Lxi;a(Lakw;)I
      intermediary method_8099 Lnet/minecraft/class_1983;method_8099(Lnet/minecraft/class_348;)I
      named calculateComparatorOutput Lnet/minecraft/screen/ScreenHandler;calculateComparatorOutput(Lnet/minecraft/block/entity/BlockEntity;)I
    • calculateComparatorOutput

      public static int calculateComparatorOutput​(Inventory inventory)
      Mappings:
      Namespace Name Mixin selector
      official b Lxi;b(Log;)I
      intermediary method_8116 Lnet/minecraft/class_1983;method_8116(Lnet/minecraft/class_1718;)I
      named calculateComparatorOutput Lnet/minecraft/screen/ScreenHandler;calculateComparatorOutput(Lnet/minecraft/inventory/Inventory;)I