Class LecternScreenHandler
- Mappings:
- Namespace - Name - official - cch- intermediary - net/minecraft/class_3916- named - net/minecraft/screen/LecternScreenHandler
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final intprivate static final intprivate static final intprivate final Inventorystatic final intstatic final intprivate final PropertyDelegatestatic final intFields 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 SummaryConstructorsConstructorDescriptionLecternScreenHandler(int syncId) LecternScreenHandler(int syncId, Inventory inventory, PropertyDelegate propertyDelegate) 
- 
Method SummaryModifier and TypeMethodDescriptionbooleancanUse(PlayerEntity player) Returns whether the screen handler can be used.intgetPage()booleanonButtonClick(PlayerEntity player, int id) Called whenplayerclicks a button withid.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.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, onClosed, onContentChanged, onSlotClick, packQuickCraftData, removeListener, sendContentUpdates, setCursorStack, setPreviousCursorStack, setPreviousTrackedSlot, setPreviousTrackedSlotMutable, setStackInSlot, shouldQuickCraftContinue, syncState, unpackQuickCraftButton, unpackQuickCraftStage, updateSlotStacks, updateSyncHandler, updateToClient
- 
Field Details- 
field_30824private static final int field_30824- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - o- Lcch;o:I- intermediary - field_30824- Lnet/minecraft/class_3916;field_30824:I- named - field_30824- Lnet/minecraft/screen/LecternScreenHandler;field_30824:I
 
- 
field_30825private static final int field_30825- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - p- Lcch;p:I- intermediary - field_30825- Lnet/minecraft/class_3916;field_30825:I- named - field_30825- Lnet/minecraft/screen/LecternScreenHandler;field_30825:I
 
- 
PREVIOUS_PAGE_BUTTON_IDpublic static final int PREVIOUS_PAGE_BUTTON_ID- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - k- Lcch;k:I- intermediary - field_30820- Lnet/minecraft/class_3916;field_30820:I- named - PREVIOUS_PAGE_BUTTON_ID- Lnet/minecraft/screen/LecternScreenHandler;PREVIOUS_PAGE_BUTTON_ID:I
 
- 
NEXT_PAGE_BUTTON_IDpublic static final int NEXT_PAGE_BUTTON_ID- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - l- Lcch;l:I- intermediary - field_30821- Lnet/minecraft/class_3916;field_30821:I- named - NEXT_PAGE_BUTTON_ID- Lnet/minecraft/screen/LecternScreenHandler;NEXT_PAGE_BUTTON_ID:I
 
- 
TAKE_BOOK_BUTTON_IDpublic static final int TAKE_BOOK_BUTTON_ID- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - m- Lcch;m:I- intermediary - field_30822- Lnet/minecraft/class_3916;field_30822:I- named - TAKE_BOOK_BUTTON_ID- Lnet/minecraft/screen/LecternScreenHandler;TAKE_BOOK_BUTTON_ID:I
 
- 
BASE_JUMP_TO_PAGE_BUTTON_IDpublic static final int BASE_JUMP_TO_PAGE_BUTTON_ID- See Also:
- Mappings:
- Namespace - Name - Mixin selector - official - n- Lcch;n:I- intermediary - field_30823- Lnet/minecraft/class_3916;field_30823:I- named - BASE_JUMP_TO_PAGE_BUTTON_ID- Lnet/minecraft/screen/LecternScreenHandler;BASE_JUMP_TO_PAGE_BUTTON_ID:I
 
- 
inventory- Mappings:
- Namespace - Name - Mixin selector - official - q- Lcch;q:Lbdq;- intermediary - field_17313- Lnet/minecraft/class_3916;field_17313:Lnet/minecraft/class_1263;- named - inventory- Lnet/minecraft/screen/LecternScreenHandler;inventory:Lnet/minecraft/inventory/Inventory;
 
- 
propertyDelegate- Mappings:
- Namespace - Name - Mixin selector - official - r- Lcch;r:Lcbp;- intermediary - field_17314- Lnet/minecraft/class_3916;field_17314:Lnet/minecraft/class_3913;- named - propertyDelegate- Lnet/minecraft/screen/LecternScreenHandler;propertyDelegate:Lnet/minecraft/screen/PropertyDelegate;
 
 
- 
- 
Constructor Details- 
LecternScreenHandlerpublic LecternScreenHandler(int syncId) - Mappings:
- Namespace - Name - Mixin selector - official - <init>- Lcch;<init>(I)V- intermediary - <init>- Lnet/minecraft/class_3916;<init>(I)V- named - <init>- Lnet/minecraft/screen/LecternScreenHandler;<init>(I)V
 
- 
LecternScreenHandler- Mappings:
- Namespace - Name - Mixin selector - official - <init>- Lcch;<init>(ILbdq;Lcbp;)V- intermediary - <init>- Lnet/minecraft/class_3916;<init>(ILnet/minecraft/class_1263;Lnet/minecraft/class_3913;)V- named - <init>- Lnet/minecraft/screen/LecternScreenHandler;<init>(ILnet/minecraft/inventory/Inventory;Lnet/minecraft/screen/PropertyDelegate;)V
 
 
- 
- 
Method Details- 
onButtonClickCalled whenplayerclicks a button withid."Button click" is an abstract concept; it does not have to be triggered by a button. Examples of button clicks include selecting a recipe for a stonecutter, turning a page of a lectern's book, or selecting an enchantment on an enchanting table. Buttons are identified by an integer. - Overrides:
- onButtonClickin class- ScreenHandler
- Returns:
- whether the button click is handled successfully
- Mappings:
- Namespace - Name - Mixin selector - official - b- Lcbf;b(Lbyo;I)Z- intermediary - method_7604- Lnet/minecraft/class_1703;method_7604(Lnet/minecraft/class_1657;I)Z- named - onButtonClick- Lnet/minecraft/screen/ScreenHandler;onButtonClick(Lnet/minecraft/entity/player/PlayerEntity;I)Z
 
- 
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;
 
- 
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
 
- 
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
 
- 
getBookItem- Mappings:
- Namespace - Name - Mixin selector - official - l- Lcch;l()Lcfz;- intermediary - method_17418- Lnet/minecraft/class_3916;method_17418()Lnet/minecraft/class_1799;- named - getBookItem- Lnet/minecraft/screen/LecternScreenHandler;getBookItem()Lnet/minecraft/item/ItemStack;
 
- 
getPagepublic int getPage()- Mappings:
- Namespace - Name - Mixin selector - official - m- Lcch;m()I- intermediary - method_17419- Lnet/minecraft/class_3916;method_17419()I- named - getPage- Lnet/minecraft/screen/LecternScreenHandler;getPage()I
 
 
-