Class PokemonUI
java.lang.Object
com.pixelmonmod.pixelmon.client.gui.widgets.PokemonUI
- Direct Known Subclasses:
SelectionPokemonUI
Created by Jay113355 on 5/16/2020.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
drawPokemon
(net.minecraft.client.gui.GuiGraphics graphics, Pokemon pokemon, int leftX, int topY, int mouseX, int mouseY, float zLevel) Draws the pokemon on the screen.void
drawPokemon
(net.minecraft.client.gui.GuiGraphics graphics, Pokemon pokemon, int leftX, int topY, int mouseX, int mouseY, float zLevel, boolean highlight) Draws the pokemon on the screen.boolean
isMouseOver
(int leftX, int topY, double mouseX, double mouseY) Checks if the cursor is over the pokemon.
-
Constructor Details
-
PokemonUI
public PokemonUI(int leftOffset, int topOffset) Creates a pokemon ui.- Parameters:
leftOffset
- The x offset of the button from the left of the screen.topOffset
- The y offset of the button from the top of the screen.
-
-
Method Details
-
drawPokemon
public void drawPokemon(net.minecraft.client.gui.GuiGraphics graphics, Pokemon pokemon, int leftX, int topY, int mouseX, int mouseY, float zLevel) Draws the pokemon on the screen.- Parameters:
leftX
- The x coordinate of the left side of the screen.topY
- The y coordinate of the top of the screen.mouseX
- The x coordinate of the cursor.mouseY
- The y coordinate of the cursor.zLevel
- The z coordinate of the button.
-
drawPokemon
public void drawPokemon(net.minecraft.client.gui.GuiGraphics graphics, Pokemon pokemon, int leftX, int topY, int mouseX, int mouseY, float zLevel, boolean highlight) Draws the pokemon on the screen.- Parameters:
leftX
- The x coordinate of the left side of the screen.topY
- The y coordinate of the top of the screen.mouseX
- The x coordinate of the cursor.mouseY
- The y coordinate of the cursor.zLevel
- The z coordinate of the button.highlight
- Whether to show an outline on the ui.
-
isMouseOver
public boolean isMouseOver(int leftX, int topY, double mouseX, double mouseY) Checks if the cursor is over the pokemon.- Parameters:
leftX
- The x coordinate of the left side of the screen.topY
- The y coordinate of the top of the screen.mouseX
- The x coordinate of the cursor.mouseY
- The y coordinate of the cursor.- Returns:
- Whether the cursor is over the button.
-