public static class TemplateRecipeHandler.RecipeTransferRectHandler extends java.lang.Object implements IContainerInputHandler, IContainerTooltipHandler
| Constructor and Description |
|---|
RecipeTransferRectHandler() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canHandle(net.minecraft.client.gui.inventory.GuiContainer gui) |
java.util.List<java.lang.String> |
handleItemDisplayName(net.minecraft.client.gui.inventory.GuiContainer gui,
ItemStack itemstack,
java.util.List<java.lang.String> currenttip)
Use this for modifying the multiline display name of an item which may not necessarily be under the mouse.
|
java.util.List<java.lang.String> |
handleItemTooltip(net.minecraft.client.gui.inventory.GuiContainer gui,
ItemStack itemstack,
int mousex,
int mousey,
java.util.List<java.lang.String> currenttip)
Use this for modifying the tooltips of items that are under the mouse.
|
java.util.List<java.lang.String> |
handleTooltip(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
java.util.List<java.lang.String> currenttip)
Use this to add tooltips for other objects.
|
boolean |
keyTyped(net.minecraft.client.gui.inventory.GuiContainer gui,
char keyChar,
int keyID)
Only use this for things like input boxes that have to be 'focused' first and will not conflict with others
|
boolean |
lastKeyTyped(net.minecraft.client.gui.inventory.GuiContainer gui,
char keyChar,
int keyCode)
This version of keyTyped is called if the key event has not been handled by the first pass, use this for key bindings that work globally
|
boolean |
mouseClicked(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button)
Called when the mouse is clicked in the gui
|
boolean |
mouseScrolled(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int scrolled) |
void |
onKeyTyped(net.minecraft.client.gui.inventory.GuiContainer gui,
char keyChar,
int keyID)
This version of keyTyped is passive and will be called on every input handler before keyTyped is processed
|
void |
onMouseClicked(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button)
This version of mouseClicked is passive and will be called on every input handler before mouseClicked is processed
|
void |
onMouseDragged(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button,
long heldTime)
This version of mouseClicked is passive and will be called on every input handler before mouseClicked is processed
|
void |
onMouseScrolled(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int scrolled)
This version of mouseScrolled is passive and will be called on every input handler before mouseScrolled is processed
|
void |
onMouseUp(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button) |
static void |
registerRectsToGuis(java.util.List<java.lang.Class<? extends net.minecraft.client.gui.inventory.GuiContainer>> classes,
java.util.List<TemplateRecipeHandler.RecipeTransferRect> rects) |
public static void registerRectsToGuis(java.util.List<java.lang.Class<? extends net.minecraft.client.gui.inventory.GuiContainer>> classes,
java.util.List<TemplateRecipeHandler.RecipeTransferRect> rects)
public boolean canHandle(net.minecraft.client.gui.inventory.GuiContainer gui)
public boolean lastKeyTyped(net.minecraft.client.gui.inventory.GuiContainer gui,
char keyChar,
int keyCode)
IContainerInputHandlerlastKeyTyped in interface IContainerInputHandlergui - An instance of the currentscreenkeyChar - The character representing the keyPresskeyCode - The KeyCode as defined in Keyboardpublic boolean mouseClicked(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button)
IContainerInputHandlermouseClicked in interface IContainerInputHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topbutton - The button index being pressed, {0 = Left Click, 1 = Right Click, 2 = Middle Click}public void onKeyTyped(net.minecraft.client.gui.inventory.GuiContainer gui,
char keyChar,
int keyID)
IContainerInputHandleronKeyTyped in interface IContainerInputHandlergui - An instance of the currentscreenkeyChar - The character representing the keyPresskeyID - The KeyCode as defined in Keyboardpublic void onMouseClicked(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button)
IContainerInputHandleronMouseClicked in interface IContainerInputHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topbutton - The button index being pressed, {0 = Left Click, 1 = Right Click, 2 = Middle Click}public void onMouseUp(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button)
onMouseUp in interface IContainerInputHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topbutton - The button index being released, {0 = Left Click, 1 = Right Click, 2 = Middle Click}public boolean keyTyped(net.minecraft.client.gui.inventory.GuiContainer gui,
char keyChar,
int keyID)
IContainerInputHandlerkeyTyped in interface IContainerInputHandlergui - An instance of the currentscreenkeyChar - The character representing the keyPresskeyID - The KeyCode as defined in Keyboardpublic boolean mouseScrolled(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int scrolled)
mouseScrolled in interface IContainerInputHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topscrolled - The number of notches scrolled. Positive for up.public void onMouseScrolled(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int scrolled)
IContainerInputHandleronMouseScrolled in interface IContainerInputHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topscrolled - The number of notches scrolled. Positive for up.public java.util.List<java.lang.String> handleTooltip(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
java.util.List<java.lang.String> currenttip)
IContainerTooltipHandlerhandleTooltip in interface IContainerTooltipHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topcurrenttip - A list of strings, representing each line of the current tooltip as modified by other handlerspublic java.util.List<java.lang.String> handleItemDisplayName(net.minecraft.client.gui.inventory.GuiContainer gui,
ItemStack itemstack,
java.util.List<java.lang.String> currenttip)
IContainerTooltipHandlerhandleItemDisplayName in interface IContainerTooltipHandlergui - An instance of the currentscreen. If only general information about the item is wanted (Eg. potion effects) then this may be null.itemstack - The ItemStack under the mousecurrenttip - A list of strings, representing each line of the current tooltip as modified by other handlerspublic java.util.List<java.lang.String> handleItemTooltip(net.minecraft.client.gui.inventory.GuiContainer gui,
ItemStack itemstack,
int mousex,
int mousey,
java.util.List<java.lang.String> currenttip)
IContainerTooltipHandlerhandleItemTooltip in interface IContainerTooltipHandlergui - An instance of the currentscreenitemstack - The ItemStack under the mousecurrenttip - A list of strings, representing each line of the current tooltip as modified by other handlerspublic void onMouseDragged(net.minecraft.client.gui.inventory.GuiContainer gui,
int mousex,
int mousey,
int button,
long heldTime)
IContainerInputHandleronMouseDragged in interface IContainerInputHandlergui - An instance of the currentscreenmousex - The x position of the mouse in pixels from leftmousey - The y position of the mouse in pixels from topbutton - The button index being pressed, {0 = Left Click, 1 = Right Click, 2 = Middle Click}heldTime - The number of milliseconds since the button was first pressed