public class PokemonBuilder
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
PokemonBuilder |
ability(@Nullable Ability ability)
Sets the ability of the Pokemon
Leaving null will allow the Pokemon initialize algorithm to calculate the relevant one for the form/gender (etc)
|
PokemonBuilder |
abilitySlot(com.mojang.datafixers.util.Pair<java.lang.Integer,java.lang.Boolean> abilitySlot)
Sets the ability slots of the Pokemon, overriding .ability()
Leaving null will allow the Pokemon initialize algorithm to calculate the relevant one for the form/gender (etc)
|
PokemonBuilder |
bonusStats(BonusStats stats)
Adds additional stats on top of normal battle stats.
|
Pokemon |
build()
Creates the Pokemon instance using the provided information
|
static PokemonBuilder |
builder()
Creates a new instance of a PokemonBuilder object
|
PokemonBuilder |
caughtBall(@NonNull PokeBall caughtBall)
Sets the ball of the Pokemon
|
static PokemonBuilder |
copy(Pokemon pokemon) |
PokemonBuilder |
displayedRibbon(Ribbon ribbon)
Specifies the selected ribbon on the Pokemon
|
PokemonBuilder |
dynamaxLevel(int dynamaxLevel)
Sets the Pokemon to have the provided Dynamax level
|
PokemonBuilder |
egg(boolean egg)
Makes the Pokemon an egg
|
PokemonBuilder |
eggSteps(java.lang.Integer eggSteps)
Sets the progress towards hatching
|
PokemonBuilder |
ev(@NonNull BattleStatsType type,
int level)
Sets the value of the EV
|
PokemonBuilder |
evs(int... evs)
Sets the EVs of the Pokemon
|
PokemonBuilder |
experience(int experience)
Sets the experience of the Pokemon
|
PokemonBuilder |
extraStats(@NonNull ExtraStats extraStats)
Sets the extra stats of the Pokemon
|
PokemonBuilder |
flags(java.util.Collection<java.lang.String> flags)
Adds flags to the Pokemon
|
PokemonBuilder |
flags(java.lang.String... flags)
Adds flags to the Pokemon
|
PokemonBuilder |
form(@NonNull Stats form)
Sets the form of the Pokemon
Setting to null selects a random default form from the species
|
PokemonBuilder |
form(@Nullable java.lang.String form)
Sets the form of the Pokemon
Setting to null selects a random default form from the species
|
PokemonBuilder |
friendship(int friendship)
Sets the friendship of the Pokemon
|
PokemonBuilder |
gender(@NonNull Gender gender)
Sets the gender of the Pokemon
|
Ability |
getAbility() |
BonusStats |
getBonusStats() |
PokeBall |
getCaughtBall() |
Ribbon |
getDisplayedRibbon() |
int |
getDynamaxLevel() |
java.lang.Integer |
getEggSteps() |
int[] |
getEvs() |
int |
getExperience() |
ExtraStats |
getExtraStats() |
java.util.List<java.lang.String> |
getFlags() |
java.lang.String |
getForm() |
int |
getFriendship() |
Gender |
getGender() |
EnumGrowth |
getGrowth() |
net.minecraft.item.ItemStack |
getHeldItem() |
boolean[] |
getHyperTrained() |
int[] |
getIvs() |
int |
getLevel() |
Nature |
getMintNature() |
Attack[] |
getMoves() |
Nature |
getNature() |
net.minecraft.util.text.ITextComponent |
getNickname() |
java.util.UUID |
getOriginalTrainer() |
java.lang.String |
getOriginalTrainerName() |
java.lang.String |
getPalette() |
net.minecraft.nbt.CompoundNBT |
getPersistentData() |
java.util.List<java.lang.String> |
getPokemonSpecs() |
Pokerus |
getPokerus() |
java.util.List<ImmutableAttack> |
getReminderMoves() |
java.util.List<Ribbon> |
getRibbons() |
Species |
getSpecies() |
StatusPersist |
getStatus() |
java.lang.String |
getTempAbility() |
java.util.UUID |
getUuid() |
PokemonBuilder |
gigantamaxFactor()
Sets the Pokemon to have the Gigantamax Factor
|
PokemonBuilder |
gigantamaxFactor(boolean gigantamaxFactor)
Sets the Pokemon to have the Gigantamax Factor if true, or not if false
|
PokemonBuilder |
growth(@Nullable EnumGrowth growth)
Sets the growth of the Pokemon
|
PokemonBuilder |
heldItem(@NonNull HeldItem heldItem)
Sets the held item of the Pokemon
|
PokemonBuilder |
heldItem(@NonNull net.minecraft.item.ItemStack heldItem)
Sets the held item of the Pokemon
|
PokemonBuilder |
hyperTrained(boolean[] hypertrainedArray)
Sets the hyper-trained status for the IVs of the Pokemon
|
boolean |
isEgg() |
boolean |
isGigantamaxFactor() |
PokemonBuilder |
iv(@NonNull BattleStatsType type,
int level)
Sets the value of the EV
|
PokemonBuilder |
ivs(int... ivs)
Sets the IVs of the Pokemon
|
PokemonBuilder |
level(int level)
Sets the level of the Pokemon
|
PokemonBuilder |
makeEgg()
Makes the Pokemon an egg
|
PokemonBuilder |
mintNature(@Nullable Nature nature)
Sets the mint nature of the Pokemon
|
PokemonBuilder |
move(int index,
@Nullable Attack attack)
Sets the move to the
Attack at the given index |
PokemonBuilder |
move(int index,
@Nullable ImmutableAttack attack)
Sets the move to the
ImmutableAttack at the given index |
PokemonBuilder |
moveReminderMoves(@NonNull java.util.List<ImmutableAttack> reminderMoves)
Sets the moves this Pokémon gets from the Move Reminder
|
PokemonBuilder |
moveReminderMoves(RegistryValue<ImmutableAttack>... reminderMoves)
Sets the moves this Pokémon gets from the Move Reminder
|
PokemonBuilder |
moves(Attack... moves)
Sets the moves of the Pokemon
|
PokemonBuilder |
nature(@Nullable Nature nature)
Sets the nature of the Pokemon
|
PokemonBuilder |
nickname(@Nullable net.minecraft.util.text.ITextComponent nickname)
Sets the nickname of the Pokemon
Leaving null means no nickname
|
PokemonBuilder |
nickname(@Nullable java.lang.String nickname)
Sets the nickname of the Pokemon
Leaving null means no nickname
|
PokemonBuilder |
originalTrainer(@Nullable net.minecraft.entity.player.PlayerEntity player)
Sets the original trainer UUID of the Pokemon
|
PokemonBuilder |
originalTrainer(@Nullable java.util.UUID originalTrainer,
@Nullable java.lang.String originalTrainerName)
Sets the original trainer UUID of the Pokemon
|
PokemonBuilder |
palette(@Nullable java.lang.String palette)
Sets the palette of the Pokemon
Setting to null selects a random default palette from the form
|
PokemonBuilder |
persistentData(net.minecraft.nbt.CompoundNBT data)
Adds the persistent nbt data for the pokemon
|
PokemonBuilder |
pokerus(@NonNull Pokerus pokerus)
Sets the pokerus status of the Pokemon
|
PokemonBuilder |
randomSpecies()
Sets the species to a randomly selected species using
PixelmonSpecies.getRandomSpecies() |
PokemonBuilder |
randomSpecies(boolean excludeLegendaries,
boolean excludeMythicals,
boolean excludeUltraBeasts)
Sets the species to a randomly selected species using
PixelmonSpecies.getRandomSpecies(boolean, boolean, boolean) } |
PokemonBuilder |
randomSpecies(java.util.Collection<RegistryValue<Species>> excluded)
Sets the species to a random species excluding those given
|
PokemonBuilder |
randomSpecies(java.util.function.Predicate<Species> excluded)
Sets the species to a random species excluding those set to be excluded in the predicate
|
PokemonBuilder |
randomSpecies(RegistryValue<Species>... excluded)
Sets the species to a random species excluding those given
|
PokemonBuilder |
ribbons(java.util.Collection<Ribbon> ribbons)
Adds ribbons to the Pokemon
|
PokemonBuilder |
shiny()
Sets the Pokemon palette to be shiny
|
PokemonBuilder |
shiny(boolean shiny)
Sets the Pokemon palette to be shiny if true, null if false
|
PokemonBuilder |
species(int ndex)
Sets the species
|
PokemonBuilder |
species(@NonNull java.util.Optional<Species> species)
Sets the species
|
PokemonBuilder |
species(@NonNull RegistryValue<Species> species)
Sets the species
|
PokemonBuilder |
species(@NonNull Species species)
Sets the species
|
PokemonBuilder |
species(@NonNull java.lang.String speciesName)
Sets the species
|
PokemonBuilder |
specs(java.util.Collection<java.lang.String> specs)
Adds post-creation specs to apply
|
PokemonBuilder |
specs(PokemonSpecification... specs)
Adds post-creation specs to apply
|
PokemonBuilder |
specs(java.lang.String... specs)
Adds post-creation specs to apply
|
PokemonBuilder |
status(@NonNull StatusPersist status)
Sets the status of the Pokemon
|
PokemonBuilder |
tempAbility(java.lang.String ability)
Sets the temp ability of the Pokémon, stored in Moveset
|
PokemonBuilder |
uuid(@Nullable java.util.UUID uuid)
Sets the UUID
Setting to null selects a random UUID
|
public static PokemonBuilder copy(Pokemon pokemon)
public static PokemonBuilder builder()
public PokemonBuilder uuid(@Nullable java.util.UUID uuid)
uuid
- The new UUIDpublic PokemonBuilder randomSpecies()
PixelmonSpecies.getRandomSpecies()
public PokemonBuilder randomSpecies(boolean excludeLegendaries, boolean excludeMythicals, boolean excludeUltraBeasts)
PixelmonSpecies.getRandomSpecies(boolean, boolean, boolean)
}excludeLegendaries
- - Whether or not Legendaries are includedexcludeMythicals
- - Whether or not Mythicals are includedexcludeUltraBeasts
- - Whether or not Ultra Beasts are includedpublic PokemonBuilder randomSpecies(java.util.Collection<RegistryValue<Species>> excluded)
excluded
- The pokemon to excludepublic PokemonBuilder randomSpecies(RegistryValue<Species>... excluded)
excluded
- The pokemon to excludepublic PokemonBuilder randomSpecies(java.util.function.Predicate<Species> excluded)
excluded
- The pokemon to exclude (returning true means it will be excluded - false means it will be accepted)public PokemonBuilder species(@NonNull java.lang.String speciesName)
speciesName
- The name of the speciespublic PokemonBuilder species(@NonNull RegistryValue<Species> species)
species
- The species registry valuepublic PokemonBuilder species(@NonNull java.util.Optional<Species> species)
species
- The species optionalpublic PokemonBuilder species(int ndex)
ndex
- The species national dex IDpublic PokemonBuilder species(@NonNull Species species)
species
- The speciespublic PokemonBuilder makeEgg()
public PokemonBuilder egg(boolean egg)
public PokemonBuilder eggSteps(java.lang.Integer eggSteps)
public PokemonBuilder gender(@NonNull Gender gender)
gender
- The genderpublic PokemonBuilder shiny()
public PokemonBuilder shiny(boolean shiny)
public PokemonBuilder palette(@Nullable java.lang.String palette)
palette
- The palettepublic PokemonBuilder form(@NonNull Stats form)
form
- The formpublic PokemonBuilder form(@Nullable java.lang.String form)
form
- The formpublic PokemonBuilder ability(@Nullable Ability ability)
ability
- The abilitypublic PokemonBuilder abilitySlot(com.mojang.datafixers.util.Pair<java.lang.Integer,java.lang.Boolean> abilitySlot)
abilitySlot
- The index of the abilityusesHidden
- Whether the ability should be the hidden abilitypublic PokemonBuilder tempAbility(java.lang.String ability)
ability
- The name of the abilitypublic PokemonBuilder nickname(@Nullable java.lang.String nickname)
nickname
- The nicknamepublic PokemonBuilder nickname(@Nullable net.minecraft.util.text.ITextComponent nickname)
nickname
- The nicknamepublic PokemonBuilder heldItem(@NonNull HeldItem heldItem)
heldItem
- The held item typepublic PokemonBuilder heldItem(@NonNull net.minecraft.item.ItemStack heldItem)
heldItem
- The held itemstackpublic PokemonBuilder friendship(int friendship)
friendship
- The new friendshippublic PokemonBuilder experience(int experience)
experience
- The new experiencepublic PokemonBuilder ev(@NonNull BattleStatsType type, int level)
type
- The type of EVlevel
- the levelpublic PokemonBuilder iv(@NonNull BattleStatsType type, int level)
type
- The type of EVlevel
- the levelpublic PokemonBuilder evs(int... evs)
evs
- The evspublic PokemonBuilder ivs(int... ivs)
ivs
- The ivspublic PokemonBuilder hyperTrained(boolean[] hypertrainedArray)
hypertrainedArray
- Whether each IV is hyper-trainedpublic PokemonBuilder move(int index, @Nullable ImmutableAttack attack)
ImmutableAttack
at the given indexindex
- The index of the move in the party (0-3)attack
- The attackpublic PokemonBuilder move(int index, @Nullable Attack attack)
Attack
at the given indexindex
- The index of the move in the party (0-3)attack
- The attackpublic PokemonBuilder moves(Attack... moves)
moves
- The movespublic PokemonBuilder moveReminderMoves(RegistryValue<ImmutableAttack>... reminderMoves)
reminderMoves
- The moves to applypublic PokemonBuilder moveReminderMoves(@NonNull java.util.List<ImmutableAttack> reminderMoves)
reminderMoves
- The moves to applypublic PokemonBuilder nature(@Nullable Nature nature)
nature
- The naturepublic PokemonBuilder growth(@Nullable EnumGrowth growth)
growth
- The growthpublic PokemonBuilder mintNature(@Nullable Nature nature)
nature
- The mint naturepublic PokemonBuilder level(int level)
level
- The levelpublic PokemonBuilder caughtBall(@NonNull PokeBall caughtBall)
caughtBall
- The ballpublic PokemonBuilder extraStats(@NonNull ExtraStats extraStats)
extraStats
- The extra stats for the speciespublic PokemonBuilder originalTrainer(@Nullable java.util.UUID originalTrainer, @Nullable java.lang.String originalTrainerName)
originalTrainer
- The original traineroriginalTrainerName
- The original trainer's namepublic PokemonBuilder originalTrainer(@Nullable net.minecraft.entity.player.PlayerEntity player)
player
- The original trainerpublic PokemonBuilder specs(java.lang.String... specs)
specs
- The specs to applypublic PokemonBuilder specs(java.util.Collection<java.lang.String> specs)
specs
- The specs to applypublic PokemonBuilder specs(PokemonSpecification... specs)
specs
- The specs to applypublic PokemonBuilder pokerus(@NonNull Pokerus pokerus)
pokerus
- The pokeruspublic PokemonBuilder status(@NonNull StatusPersist status)
status
- The statuspublic PokemonBuilder gigantamaxFactor()
public PokemonBuilder gigantamaxFactor(boolean gigantamaxFactor)
public PokemonBuilder dynamaxLevel(int dynamaxLevel)
public PokemonBuilder flags(java.lang.String... flags)
flags
- The flagspublic PokemonBuilder flags(java.util.Collection<java.lang.String> flags)
flags
- The flagspublic PokemonBuilder ribbons(java.util.Collection<Ribbon> ribbons)
flags
- The ribbonspublic PokemonBuilder displayedRibbon(Ribbon ribbon)
ribbon
- The ribbonpublic PokemonBuilder bonusStats(BonusStats stats)
stats
- The stats to be addedpublic PokemonBuilder persistentData(net.minecraft.nbt.CompoundNBT data)
data
- The nbt datapublic java.util.UUID getUuid()
public Species getSpecies()
public java.lang.String getPalette()
public java.lang.String getForm()
public boolean isEgg()
public java.lang.Integer getEggSteps()
public Gender getGender()
public Ability getAbility()
public net.minecraft.util.text.ITextComponent getNickname()
public net.minecraft.item.ItemStack getHeldItem()
public int getFriendship()
public int[] getIvs()
public boolean[] getHyperTrained()
public int[] getEvs()
public Attack[] getMoves()
public java.util.List<ImmutableAttack> getReminderMoves()
public java.lang.String getTempAbility()
public Nature getNature()
public Nature getMintNature()
public int getLevel()
public int getExperience()
public EnumGrowth getGrowth()
public PokeBall getCaughtBall()
public ExtraStats getExtraStats()
public java.util.UUID getOriginalTrainer()
public java.lang.String getOriginalTrainerName()
public Pokerus getPokerus()
public StatusPersist getStatus()
public boolean isGigantamaxFactor()
public int getDynamaxLevel()
public Ribbon getDisplayedRibbon()
public java.util.List<Ribbon> getRibbons()
public java.util.List<java.lang.String> getFlags()
public java.util.List<java.lang.String> getPokemonSpecs()
public BonusStats getBonusStats()
public net.minecraft.nbt.CompoundNBT getPersistentData()
public Pokemon build()