java.lang.Object
com.pixelmonmod.pixelmon.client.gui.widgets.PokemonUI
Direct Known Subclasses:
SelectionPokemonUI

public class PokemonUI extends Object
Created by Jay113355 on 5/16/2020.
  • Constructor Summary

    Constructors
    Constructor
    Description
    PokemonUI(int leftOffset, int topOffset)
    Creates a pokemon ui.
  • Method Summary

    Modifier and Type
    Method
    Description
    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.
    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.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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.