Class BeaconScreenHandler
- Mappings:
- Namespace - Name - official - cbi- intermediary - net/minecraft/class_1704- named - net/minecraft/screen/BeaconScreenHandler
- 
Nested Class SummaryNested Classes
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate static final intprivate final ScreenHandlerContextprivate static final intprivate static final intprivate static final intprivate static final intprivate final Inventoryprivate static final intprivate final BeaconScreenHandler.PaymentSlotprivate static final intprivate final PropertyDelegateFields inherited from class net.minecraft.screen.ScreenHandlerEMPTY_SPACE_SLOT_INDEX, field_30731, field_30732, field_30733, field_30734, field_30735, field_30736, field_30737, slots, syncId
- 
Constructor SummaryConstructorsConstructorDescriptionBeaconScreenHandler(int syncId, Inventory inventory) BeaconScreenHandler(int syncId, Inventory inventory, PropertyDelegate propertyDelegate, ScreenHandlerContext context) 
- 
Method SummaryModifier and TypeMethodDescriptionbooleancanUse(PlayerEntity player) Returns whether the screen handler can be used.intbooleanvoidonClosed(PlayerEntity player) Called when this screen handler is closed.quickMove(PlayerEntity player, int slot) Quick-moves the stack atslotto other slots of the screen handler that belong to a different inventory or another section of the same inventory.voidsetEffects(Optional<StatusEffect> primary, Optional<StatusEffect> secondary) voidsetProperty(int id, int value) Sets the property with IDidtovalue.Methods inherited from class net.minecraft.screen.ScreenHandleraddListener, addProperties, addProperty, addSlot, calculateComparatorOutput, calculateComparatorOutput, calculateStackSize, canInsertIntoSlot, canInsertIntoSlot, canInsertItemIntoSlot, canUse, checkDataCount, checkSize, copySharedSlots, disableSyncing, dropInventory, enableSyncing, endQuickCraft, getCursorStack, getRevision, getSlot, getSlotIndex, getStacks, getType, insertItem, isValid, nextRevision, onButtonClick, onContentChanged, onSlotClick, packQuickCraftData, removeListener, sendContentUpdates, setCursorStack, setPreviousCursorStack, setPreviousTrackedSlot, setPreviousTrackedSlotMutable, setStackInSlot, shouldQuickCraftContinue, syncState, unpackQuickCraftButton, unpackQuickCraftStage, updateSlotStacks, updateSyncHandler, updateToClient
- 
Field Details- 
PAYMENT_SLOT_IDprivate static final int PAYMENT_SLOT_ID- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - k- Lcbi;k:I- intermediary - field_30756- Lnet/minecraft/class_1704;field_30756:I- named - PAYMENT_SLOT_ID- Lnet/minecraft/screen/BeaconScreenHandler;PAYMENT_SLOT_ID:I
 
- 
BEACON_INVENTORY_SIZEprivate static final int BEACON_INVENTORY_SIZE- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - l- Lcbi;l:I- intermediary - field_30757- Lnet/minecraft/class_1704;field_30757:I- named - BEACON_INVENTORY_SIZE- Lnet/minecraft/screen/BeaconScreenHandler;BEACON_INVENTORY_SIZE:I
 
- 
PROPERTY_COUNTprivate static final int PROPERTY_COUNT- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - m- Lcbi;m:I- intermediary - field_30758- Lnet/minecraft/class_1704;field_30758:I- named - PROPERTY_COUNT- Lnet/minecraft/screen/BeaconScreenHandler;PROPERTY_COUNT:I
 
- 
INVENTORY_STARTprivate static final int INVENTORY_START- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - n- Lcbi;n:I- intermediary - field_30759- Lnet/minecraft/class_1704;field_30759:I- named - INVENTORY_START- Lnet/minecraft/screen/BeaconScreenHandler;INVENTORY_START:I
 
- 
INVENTORY_ENDprivate static final int INVENTORY_END- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - o- Lcbi;o:I- intermediary - field_30760- Lnet/minecraft/class_1704;field_30760:I- named - INVENTORY_END- Lnet/minecraft/screen/BeaconScreenHandler;INVENTORY_END:I
 
- 
HOTBAR_STARTprivate static final int HOTBAR_START- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - p- Lcbi;p:I- intermediary - field_30761- Lnet/minecraft/class_1704;field_30761:I- named - HOTBAR_START- Lnet/minecraft/screen/BeaconScreenHandler;HOTBAR_START:I
 
- 
HOTBAR_ENDprivate static final int HOTBAR_END- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - q- Lcbi;q:I- intermediary - field_30762- Lnet/minecraft/class_1704;field_30762:I- named - HOTBAR_END- Lnet/minecraft/screen/BeaconScreenHandler;HOTBAR_END:I
 
- 
payment- Mappings:
- Namespace - Name - Mixin selector - official - r- Lcbi;r:Lbdq;- intermediary - field_17287- Lnet/minecraft/class_1704;field_17287:Lnet/minecraft/class_1263;- named - payment- Lnet/minecraft/screen/BeaconScreenHandler;payment:Lnet/minecraft/inventory/Inventory;
 
- 
paymentSlot- Mappings:
- Namespace - Name - Mixin selector - official - s- Lcbi;s:Lcbi$a;- intermediary - field_17288- Lnet/minecraft/class_1704;field_17288:Lnet/minecraft/class_1704$class_1705;- named - paymentSlot- Lnet/minecraft/screen/BeaconScreenHandler;paymentSlot:Lnet/minecraft/screen/BeaconScreenHandler$PaymentSlot;
 
- 
context- Mappings:
- Namespace - Name - Mixin selector - official - t- Lcbi;t:Lcbq;- intermediary - field_17289- Lnet/minecraft/class_1704;field_17289:Lnet/minecraft/class_3914;- named - context- Lnet/minecraft/screen/BeaconScreenHandler;context:Lnet/minecraft/screen/ScreenHandlerContext;
 
- 
propertyDelegate- Mappings:
- Namespace - Name - Mixin selector - official - u- Lcbi;u:Lcbp;- intermediary - field_17290- Lnet/minecraft/class_1704;field_17290:Lnet/minecraft/class_3913;- named - propertyDelegate- Lnet/minecraft/screen/BeaconScreenHandler;propertyDelegate:Lnet/minecraft/screen/PropertyDelegate;
 
 
- 
- 
Constructor Details- 
BeaconScreenHandler- Mappings:
- Namespace - Name - Mixin selector - official - <init>- Lcbi;<init>(ILbdq;)V- intermediary - <init>- Lnet/minecraft/class_1704;<init>(ILnet/minecraft/class_1263;)V- named - <init>- Lnet/minecraft/screen/BeaconScreenHandler;<init>(ILnet/minecraft/inventory/Inventory;)V
 
- 
BeaconScreenHandlerpublic BeaconScreenHandler(int syncId, Inventory inventory, PropertyDelegate propertyDelegate, ScreenHandlerContext context) - Mappings:
- Namespace - Name - Mixin selector - official - <init>- Lcbi;<init>(ILbdq;Lcbp;Lcbq;)V- intermediary - <init>- Lnet/minecraft/class_1704;<init>(ILnet/minecraft/class_1263;Lnet/minecraft/class_3913;Lnet/minecraft/class_3914;)V- named - <init>- Lnet/minecraft/screen/BeaconScreenHandler;<init>(ILnet/minecraft/inventory/Inventory;Lnet/minecraft/screen/PropertyDelegate;Lnet/minecraft/screen/ScreenHandlerContext;)V
 
 
- 
- 
Method Details- 
onClosedCalled when this screen handler is closed.To close a screen handler, call PlayerEntity.closeHandledScreen()on the server instead of this method.This drops the cursor stack by default. Subclasses that have slots not backed by a persistent inventory should call ScreenHandler.dropInventory(net.minecraft.entity.player.PlayerEntity, net.minecraft.inventory.Inventory)to drop the stacks.- Overrides:
- onClosedin class- ScreenHandler
- Mappings:
- Namespace - Name - Mixin selector - official - b- Lcbf;b(Lbyo;)V- intermediary - method_7595- Lnet/minecraft/class_1703;method_7595(Lnet/minecraft/class_1657;)V- named - onClosed- Lnet/minecraft/screen/ScreenHandler;onClosed(Lnet/minecraft/entity/player/PlayerEntity;)V
 
- 
canUseReturns whether the screen handler can be used.Subclasses should call #canUse(ScreenHandlerContext, PlayerEntity, Block)} or implement the check itself. The implementation should check that the player is near the screen handler's source position (e.g. block position) and that the source (e.g. block) is not destroyed. - Specified by:
- canUsein class- ScreenHandler
- Returns:
- whether the screen handler can be used
- Mappings:
- Namespace - Name - Mixin selector - official - a- Lcbf;a(Lbyo;)Z- intermediary - method_7597- Lnet/minecraft/class_1703;method_7597(Lnet/minecraft/class_1657;)Z- named - canUse- Lnet/minecraft/screen/ScreenHandler;canUse(Lnet/minecraft/entity/player/PlayerEntity;)Z
 
- 
setPropertypublic void setProperty(int id, int value) Sets the property with IDidtovalue.Subclasses can call ScreenHandler.sendContentUpdates()to manually sync the change to the client.- Overrides:
- setPropertyin class- ScreenHandler
- Mappings:
- Namespace - Name - Mixin selector - official - a- Lcbf;a(II)V- intermediary - method_7606- Lnet/minecraft/class_1703;method_7606(II)V- named - setProperty- Lnet/minecraft/screen/ScreenHandler;setProperty(II)V
 
- 
quickMoveQuick-moves the stack atslotto other slots of the screen handler that belong to a different inventory or another section of the same inventory. For example, items can be quick-moved between a chest's slots and the player inventory or between the main player inventory and the hotbar.Subclasses should call ScreenHandler.insertItem(net.minecraft.item.ItemStack, int, int, boolean), and if the insertion was successful, clear the slot (if the stack is exhausted) or mark it as dirty. See the vanilla subclasses for basic implementation.Quick-moving is also known as "shift-clicking" since it's usually triggered using Shift+left click. - Specified by:
- quickMovein class- ScreenHandler
- Parameters:
- slot- the index of the slot to quick-move from
- Returns:
- ItemStack.EMPTYwhen no stack can be transferred, otherwise the original stack
- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - a- Lcbf;a(Lbyo;I)Lcfz;- intermediary - method_7601- Lnet/minecraft/class_1703;method_7601(Lnet/minecraft/class_1657;I)Lnet/minecraft/class_1799;- named - quickMove- Lnet/minecraft/screen/ScreenHandler;quickMove(Lnet/minecraft/entity/player/PlayerEntity;I)Lnet/minecraft/item/ItemStack;
 
- 
getPropertiespublic int getProperties()- Mappings:
- Namespace - Name - Mixin selector - official - l- Lcbi;l()I- intermediary - method_17373- Lnet/minecraft/class_1704;method_17373()I- named - getProperties- Lnet/minecraft/screen/BeaconScreenHandler;getProperties()I
 
- 
getPrimaryEffect- Mappings:
- Namespace - Name - Mixin selector - official - m- Lcbi;m()Lbey;- intermediary - method_17374- Lnet/minecraft/class_1704;method_17374()Lnet/minecraft/class_1291;- named - getPrimaryEffect- Lnet/minecraft/screen/BeaconScreenHandler;getPrimaryEffect()Lnet/minecraft/entity/effect/StatusEffect;
 
- 
getSecondaryEffect- Mappings:
- Namespace - Name - Mixin selector - official - n- Lcbi;n()Lbey;- intermediary - method_17375- Lnet/minecraft/class_1704;method_17375()Lnet/minecraft/class_1291;- named - getSecondaryEffect- Lnet/minecraft/screen/BeaconScreenHandler;getSecondaryEffect()Lnet/minecraft/entity/effect/StatusEffect;
 
- 
setEffects- Mappings:
- Namespace - Name - Mixin selector - official - a- Lcbi;a(Ljava/util/Optional;Ljava/util/Optional;)V- intermediary - method_17372- Lnet/minecraft/class_1704;method_17372(Ljava/util/Optional;Ljava/util/Optional;)V- named - setEffects- Lnet/minecraft/screen/BeaconScreenHandler;setEffects(Ljava/util/Optional;Ljava/util/Optional;)V
 
- 
hasPaymentpublic boolean hasPayment()- Mappings:
- Namespace - Name - Mixin selector - official - o- Lcbi;o()Z- intermediary - method_17376- Lnet/minecraft/class_1704;method_17376()Z- named - hasPayment- Lnet/minecraft/screen/BeaconScreenHandler;hasPayment()Z
 
 
-