Class PixelmonClientData
java.lang.Object
com.pixelmonmod.pixelmon.client.gui.battles.PixelmonClientData
Object for displaying Pokemon in the GUI.
-
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanWhether this Pokémon is blocked from capture by BonusStats.The index of the boss mode of the Pokémon.Dynamax state of the Pokémon.floatThe fraction of experience that the Pokémon has gained in its pokemonLevel.The Pokémon's form.shortThe index of the Pokémon's gender.booleanWhether the Pokémon has the Gigantamax Factor.com.google.common.util.concurrent.AtomicDoubleThe current hp of the Pokémon.The Pokémon's held item.booleanWhether this Pokémon is in disguise.booleanWhether the Pokémon is currently switching in for a Pokémon.booleanWhether the Pokémon is currently switching out for another Pokémon.intThe Pokémon's pokemonLevel.booleanintThe maximum hp of the Pokémon.intNumber of shields in raids.booleanMega Evolution state of the Pokémon.The Pokémon's moveset.net.minecraft.network.chat.MutableComponentThe Pokémon's nickname.The UUID of the entity that owns this battle participant, if one exists.Whether the Pokémon is Shiny.The UUID of the Pokémon.intThe position of the Pokémon.The Pokémon's previous form.intThe Pokémon's species.intThe index of the Pokémon non-volatile status.booleanTerastallization state of the Pokémon.protected ColorintThe x coordinate of the Pokémon on the GUI. -
Constructor Summary
ConstructorsConstructorDescriptionInitializes an empty Pokémon.PixelmonClientData(Pokemon poke) Initializes a Pokémon.PixelmonClientData(PixelmonWrapper pixelmon) Initializes a Pokémon.PixelmonClientData(net.minecraft.network.FriendlyByteBuf buffer) -
Method Summary
Modifier and TypeMethodDescriptionvoidstatic PixelmonClientData[]convertToGUI(List<PixelmonWrapper> pokemon) Converts a PixelmonWrapper list into a GUI-friendly version.voidcopyFrom(PixelmonClientData source) Copies this client display data from another instance.voiddecodeFrom(net.minecraft.network.FriendlyByteBuf buffer) Decodes the Pokémon's info from a data buffer.voidencodeInto(net.minecraft.network.FriendlyByteBuf buffer) Encodes the Pokémon's info into a data buffer.booleanintGets the Pokédex number of the Pokémon.net.minecraft.network.chat.MutableComponentReturns the Pokémon's nickname.static ColorgetHealthColor(double health, int maxHealth) float[]getTypes()inthashCode()booleanintinterpolatedXPos(float partialTicks) voidSets the Pokémon's data.voidsetAnimatedXPos(float xPos) voidvoidsnapAnimatedXPos(int xPos)
-
Field Details
-
pokemonUUID
The UUID of the Pokémon. -
ownerUUID
The UUID of the entity that owns this battle participant, if one exists. -
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
Dynamax state of the Pokémon. -
mega
public boolean megaMega Evolution state of the Pokémon. -
terastallize
public boolean terastallizeTerastallization state of the Pokémon. -
types
-
teraTypeColor
-
nickname
public net.minecraft.network.chat.MutableComponent nicknameThe Pokémon's nickname. -
status
public int statusThe index of the Pokémon non-volatile status. The possible values are located inStatusType. -
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
public PixelmonClientData(net.minecraft.network.FriendlyByteBuf buffer) -
PixelmonClientData
Initializes a Pokémon.- Parameters:
pixelmon- The Pokémon to initialize.
-
-
Method Details
-
beginAnimatedXPos
public void beginAnimatedXPos() -
setAnimatedXPos
public void setAnimatedXPos(float xPos) -
snapAnimatedXPos
public void snapAnimatedXPos(int xPos) -
interpolatedXPos
public int interpolatedXPos(float partialTicks) -
copyFrom
Copies this client display data from another instance.- Parameters:
source- The source data to copy from.
-
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
-
getTypes
-
hasType
-
setTypes
-
getTeraTypeColor
-
toPokemonBase
-
equals
-
hashCode
public int hashCode()
-