User Tools

Site Tools


tutorial:screenhandler

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
tutorial:screenhandler [2022/12/21 01:41] – item groups in 1.19.3 haykamtutorial:screenhandler [2024/02/19 02:51] (current) – [ScreenHandler and Screen] transferSlot -> quickMove per yarn mappings netuserget
Line 217: Line 217:
     // Shift + Player Inv Slot     // Shift + Player Inv Slot
     @Override     @Override
-    public ItemStack transferSlot(PlayerEntity player, int invSlot) {+    public ItemStack quickMove(PlayerEntity player, int invSlot) {
         ItemStack newStack = ItemStack.EMPTY;         ItemStack newStack = ItemStack.EMPTY;
         Slot slot = this.slots.get(invSlot);         Slot slot = this.slots.get(invSlot);
Line 261: Line 261:
         int y = (height - backgroundHeight) / 2;         int y = (height - backgroundHeight) / 2;
         drawTexture(matrices, x, y, 0, 0, backgroundWidth, backgroundHeight);         drawTexture(matrices, x, y, 0, 0, backgroundWidth, backgroundHeight);
 +        //in 1.20 or above,this method is in DrawContext class.
     }     }
  
tutorial/screenhandler.1671586891.txt.gz · Last modified: 2022/12/21 01:41 by haykam