Class PixelmonClientData
java.lang.Object
com.pixelmonmod.pixelmon.client.gui.battles.PixelmonClientData
Object for displaying Pokemon in the GUI.
-
Field Summary
Modifier and TypeFieldDescriptionboolean
Whether this Pokémon is blocked from capture by BonusStats.The index of the boss mode of the Pokémon.int
Dynamax/Mega state of the Pokémon.float
The fraction of experience that the Pokémon has gained in its pokemonLevel.The Pokémon's form.short
The index of the Pokémon's gender.boolean
Whether the Pokémon has the Gigantamax Factor.com.google.common.util.concurrent.AtomicDouble
The current hp of the Pokémon.The Pokémon's held item.boolean
Whether this Pokémon is in disguise.boolean
Whether the Pokémon is currently switching in for a Pokémon.boolean
Whether the Pokémon is currently switching out for another Pokémon.int
The Pokémon's pokemonLevel.boolean
int
The maximum hp of the Pokémon.int
Number of shields in raids.boolean
The Pokémon's moveset.net.minecraft.network.chat.MutableComponent
The Pokémon's nickname.Whether the Pokémon is Shiny.The UUID of the Pokémon.int
The position of the Pokémon.The Pokémon's previous form.int
The Pokémon's species.int
The index of the Pokémon non-volatile status.int
The x coordinate of the Pokémon on the GUI. -
Constructor Summary
ConstructorDescriptionInitializes an empty Pokémon.PixelmonClientData
(Pokemon poke) Initializes a Pokémon.PixelmonClientData
(PixelmonWrapper pixelmon) Initializes a Pokémon. -
Method Summary
Modifier and TypeMethodDescriptionstatic PixelmonClientData[]
convertToGUI
(List<PixelmonWrapper> pokemon) Converts a PixelmonWrapper list into a GUI-friendly version.void
decodeFrom
(net.minecraft.network.FriendlyByteBuf buffer) Decodes the Pokémon's info from a data buffer.void
encodeInto
(net.minecraft.network.FriendlyByteBuf buffer) Encodes the Pokémon's info into a data buffer.boolean
int
Gets the Pokédex number of the Pokémon.net.minecraft.network.chat.MutableComponent
Returns the Pokémon's nickname.static Color
getHealthColor
(double health, int maxHealth) float[]
int
hashCode()
void
Sets the Pokémon's data.
-
Field Details
-
pokemonUUID
The UUID of the Pokémon. -
species
The Pokémon's species. -
form
The Pokémon's form. -
prevForm
The Pokémon's previous form. -
gender
public short genderThe index of the Pokémon's gender. -
health
public com.google.common.util.concurrent.AtomicDouble healthThe current hp of the Pokémon. -
maxHealth
public int maxHealthThe maximum hp of the Pokémon. -
dynamax
public int dynamaxDynamax/Mega state of the Pokémon. -
mega
public boolean mega -
nickname
public net.minecraft.network.chat.MutableComponent nicknameThe Pokémon's nickname. -
status
public int statusThe index of the Pokémon non-volatile status. -
level
public int levelThe Pokémon's pokemonLevel. -
bossTier
The index of the boss mode of the Pokémon. -
palette
Whether the Pokémon is Shiny. -
gmaxFactor
public boolean gmaxFactorWhether the Pokémon has the Gigantamax Factor. -
position
public int positionThe position of the Pokémon. -
moveset
The Pokémon's moveset. -
heldItem
The Pokémon's held item. -
expFraction
public float expFractionThe fraction of experience that the Pokémon has gained in its pokemonLevel. -
xPos
public int xPosThe x coordinate of the Pokémon on the GUI. -
isSwitchingOut
public boolean isSwitchingOutWhether the Pokémon is currently switching out for another Pokémon. -
isSwitchingIn
public boolean isSwitchingInWhether the Pokémon is currently switching in for a Pokémon. -
blockCapture
public boolean blockCaptureWhether this Pokémon is blocked from capture by BonusStats. -
inIllusion
public boolean inIllusionWhether this Pokémon is in disguise. -
maxShields
public int maxShieldsNumber of shields in raids. -
shields
public int shields -
lostShield
public boolean lostShield
-
-
Constructor Details
-
PixelmonClientData
public PixelmonClientData()Initializes an empty Pokémon. -
PixelmonClientData
Initializes a Pokémon.- Parameters:
poke
- The data of the Pokémon to initialize.
-
PixelmonClientData
Initializes a Pokémon.- Parameters:
pixelmon
- The Pokémon to initialize.
-
-
Method Details
-
set
Sets the Pokémon's data.- Parameters:
poke
- The data to set the Pokémon to.
-
convertToGUI
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 net.minecraft.network.chat.MutableComponent 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
-
getGender
-
getStatusTexturePos
public float[] getStatusTexturePos() -
getHealthColor
-
equals
-
hashCode
public int hashCode()
-