Class PixelmonClientData

java.lang.Object
com.pixelmonmod.pixelmon.client.gui.battles.PixelmonClientData

public class PixelmonClientData extends Object
Object for displaying Pokemon in the GUI.
  • Field Details

    • pokemonUUID

      public UUID pokemonUUID
      The UUID of the Pokémon.
    • species

      public Species species
      The Pokémon's species.
    • form

      public String form
      The Pokémon's form.
    • prevForm

      public String prevForm
      The Pokémon's previous form.
    • gender

      public short gender
      The index of the Pokémon's gender.
    • health

      public com.google.common.util.concurrent.AtomicDouble health
      The current hp of the Pokémon.
    • maxHealth

      public int maxHealth
      The maximum hp of the Pokémon.
    • dynamax

      public int dynamax
      Dynamax/Mega state of the Pokémon.
    • mega

      public boolean mega
    • nickname

      public String nickname
      The Pokémon's nickname.
    • status

      public int status
      The index of the Pokémon non-volatile status.
    • level

      public int level
      The Pokémon's pokemonLevel.
    • bossTier

      public BossTier bossTier
      The index of the boss mode of the Pokémon.
    • palette

      public String palette
      Whether the Pokémon is Shiny.
    • gmaxFactor

      public boolean gmaxFactor
      Whether the Pokémon has the Gigantamax Factor.
    • position

      public int position
      The position of the Pokémon.
    • moveset

      public Moveset moveset
      The Pokémon's moveset.
    • heldItem

      public HeldItem heldItem
      The Pokémon's held item.
    • expFraction

      public float expFraction
      The fraction of experience that the Pokémon has gained in its pokemonLevel.
    • xPos

      public int xPos
      The x coordinate of the Pokémon on the GUI.
    • isSwitchingOut

      public boolean isSwitchingOut
      Whether the Pokémon is currently switching out for another Pokémon.
    • isSwitchingIn

      public boolean isSwitchingIn
      Whether the Pokémon is currently switching in for a Pokémon.
    • blockCapture

      public boolean blockCapture
      Whether this Pokémon is blocked from capture by BonusStats.
    • inIllusion

      public boolean inIllusion
      Whether this Pokémon is in disguise.
    • maxShields

      public int maxShields
      Number of shields in raids.
    • shields

      public int shields
    • lostShield

      public boolean lostShield
  • Constructor Details

    • PixelmonClientData

      public PixelmonClientData()
      Initializes an empty Pokémon.
    • PixelmonClientData

      public PixelmonClientData(Pokemon poke)
      Initializes a Pokémon.
      Parameters:
      poke - The data of the Pokémon to initialize.
    • PixelmonClientData

      public PixelmonClientData(PixelmonWrapper pixelmon)
      Initializes a Pokémon.
      Parameters:
      pixelmon - The Pokémon to initialize.
  • Method Details

    • set

      public void set(Pokemon poke)
      Sets the Pokémon's data.
      Parameters:
      poke - The data to set the Pokémon to.
    • convertToGUI

      public static PixelmonClientData[] convertToGUI(List<PixelmonWrapper> pokemon)
      Converts a PixelmonWrapper list into a GUI-friendly version.
      Parameters:
      pokemon - The list of Pokémon to convert.
      Returns:
      A GUI-friendly list of the Pokémon.
    • decodeFrom

      public void decodeFrom(net.minecraft.network.FriendlyByteBuf buffer)
      Decodes the Pokémon's info from a data buffer.
      Parameters:
      buffer - The data buffer to read from.
    • encodeInto

      public void encodeInto(net.minecraft.network.FriendlyByteBuf buffer)
      Encodes the Pokémon's info into a data buffer.
      Parameters:
      buffer - The data buffer to write to.
    • getDisplayName

      public String getDisplayName()
      Returns the Pokémon's nickname.
      Returns:
      The Pokémon's nickname.
    • getDexNumber

      public int getDexNumber()
      Gets the Pokédex number of the Pokémon.
      Returns:
      The Pokédex number of the Pokémon.
    • getBaseStats

      public Stats getBaseStats()
    • getGender

      public Gender getGender()
    • getStatusTexturePos

      public float[] getStatusTexturePos()
    • getHealthColor

      public Color getHealthColor()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object