Interface BreedingLogicFactory
- All Known Implementing Classes:
PixelmonBreedingLogic
public interface BreedingLogicFactory
Interface for switching out the breeding logic implementations in the
BreedingLogicProxy
- Since:
- 24/06/2022
-
Method Summary
Modifier and TypeMethodDescriptioncalculateForm
(Pokemon parentOne, Pokemon parentTwo, Species child) Calculates the form of the child using the two parentscalculatePalette
(Pokemon parentOne, Pokemon parentTwo, Species child) Calculates the palette of the child using the two parentscalculateSpecies
(Pokemon parentOne, Pokemon parentTwo) Calculates the species created by the two parent Pokemonsboolean
Checks if the two Pokemon can breedboolean
canLearnVoltTackle
(Species species, Pokemon parentOne, Pokemon parentTwo) If the pokemon can learn volt tackle moveboolean
checkIncense
(net.minecraft.world.item.Item itemTypeParent, net.minecraft.world.item.Item itemTypeOther, Pokemon parentForEggLine, net.minecraft.world.item.Item neededItem, RegistryValue<Species> baby, RegistryValue<Species>... parents) Checks the incensefindFather
(Pokemon parentOne, Pokemon parentTwo) Obtains the father of the two parentsfindMother
(Pokemon parentOne, Pokemon parentTwo) Obtains the mother of the two parentsgetEggAbility
(Stats form, Pokemon parentOne, Pokemon parentTwo) Calculates the new Ability for the Pokemon from the two parentsgetEggAbilitySlot
(Stats form, Pokemon parentOne, Pokemon parentTwo) Calculates the new Ability slot for the Pokemon from the two parentsgetEggGrowth
(Pokemon parentOne, Pokemon parentTwo) Calculates the new Growth for the Pokemon from the two parentsgetEggMoves
(Stats egg, Pokemon parent, Set<ImmutableAttack> allEggMoves) Gets the egg movesgetEggMoveset
(Stats egg, Pokemon parentOne, Pokemon parentTwo) Calculates the egg move setgetFathersTMHMTutorMoves
(Stats egg, Pokemon father) Gets the father's TM, HM and Tutor movesgetFirstFourMoves
(List<ImmutableAttack> masterAttackList) Gets the first four moves from the attack list givengetIVsForEgg
(Pokemon parentOne, Pokemon parentTwo) Calculates the new IVs for the Pokemon from the two parentsgetNatureForEgg
(Pokemon parentOne, Pokemon parentTwo) Calculates the new Nature for the Pokemon from the two parentsgetPokeBall
(Pokemon parentOne, Pokemon parentTwo) Calculates the new PokeBall for the Pokemon from the two parentsgetPokemonLevelupMoves
(Stats egg, Pokemon parentOne, Pokemon parentTwo) Gets the level up moves for the eggAttempts to make an egg using the two given PokemonmakeRandomEgg
(Pokemon parentOne, Pokemon parentTwo) Makes a random Pokemon egg using the two parents for stats such as IVs and abilitiesboolean
shouldEggBeShiny
(Pokemon parentOne, Pokemon parentTwo) Check used to determine if the child should be shiny
-
Method Details
-
makeEgg
Attempts to make an egg using the two given Pokemon- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- The potential egg
-
calculateForm
Calculates the form of the child using the two parents- Parameters:
parentOne
- The first parentparentTwo
- The second parentchild
- The child species- Returns:
- The relevant form
-
calculatePalette
Calculates the palette of the child using the two parents- Parameters:
parentOne
- The first parentparentTwo
- The second parentchild
- The child species- Returns:
- The relevant palette
-
canBreed
Checks if the two Pokemon can breed- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- true if they can breed
-
makeRandomEgg
Makes a random Pokemon egg using the two parents for stats such as IVs and abilities- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- The new Pokemon egg
-
calculateSpecies
Calculates the species created by the two parent Pokemons- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- The created species
-
getIVsForEgg
Calculates the new IVs for the Pokemon from the two parents- Parameters:
parentOne
- First parentparentTwo
- Second parent- Returns:
- The new IVs
-
getNatureForEgg
Calculates the new Nature for the Pokemon from the two parents- Parameters:
parentOne
- First parentparentTwo
- Second parent- Returns:
- The new Nature
-
getPokeBall
Calculates the new PokeBall for the Pokemon from the two parents- Parameters:
parentOne
- First parentparentTwo
- Second parent- Returns:
- The new PokeBall
-
getEggGrowth
Calculates the new Growth for the Pokemon from the two parents- Parameters:
parentOne
- First parentparentTwo
- Second parent- Returns:
- The new Growth
-
getEggAbility
Calculates the new Ability for the Pokemon from the two parents- Parameters:
parentOne
- First parentparentTwo
- Second parent- Returns:
- The new Ability
-
getEggAbilitySlot
com.mojang.datafixers.util.Pair<Integer,Boolean> getEggAbilitySlot(Stats form, Pokemon parentOne, Pokemon parentTwo) Calculates the new Ability slot for the Pokemon from the two parents- Parameters:
parentOne
- First parentparentTwo
- Second parent- Returns:
- The new slot and whether it inherits the hidden ability
-
shouldEggBeShiny
Check used to determine if the child should be shiny- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- True if shiny
-
getEggMoveset
Calculates the egg move set- Parameters:
egg
- The egg's formparentOne
- The first parentparentTwo
- The second parent- Returns:
- The moveset of the child
-
getPokemonLevelupMoves
Gets the level up moves for the egg- Parameters:
egg
- The form of the eggparentOne
- The first parentparentTwo
- The second parent- Returns:
- The level up moves
-
getFirstFourMoves
Gets the first four moves from the attack list given- Parameters:
masterAttackList
- The attack list- Returns:
- The move set equivalent of the attack list
-
getEggMoves
Gets the egg moves- Parameters:
egg
- The egg's formparent
- The parentallEggMoves
- The child's egg moves- Returns:
- The egg moves
-
canLearnVoltTackle
If the pokemon can learn volt tackle move- Parameters:
species
- The egg speciesparentOne
- The first parentparentTwo
- The second parent- Returns:
- True if it can learn volt tackle
-
getFathersTMHMTutorMoves
Gets the father's TM, HM and Tutor moves- Parameters:
egg
- The eggfather
- The father- Returns:
- The TM, HM and Tutor moves
-
findFather
Obtains the father of the two parents- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- The father
-
findMother
Obtains the mother of the two parents- Parameters:
parentOne
- The first parentparentTwo
- The second parent- Returns:
- The mother
-
checkIncense
boolean checkIncense(net.minecraft.world.item.Item itemTypeParent, net.minecraft.world.item.Item itemTypeOther, Pokemon parentForEggLine, net.minecraft.world.item.Item neededItem, RegistryValue<Species> baby, RegistryValue<Species>... parents) Checks the incense- Parameters:
itemTypeParent
- The parent's itemitemTypeOther
- The other itemparentForEggLine
- The egg line itemneededItem
- The required itembaby
- The baby typeparents
- The parents types- Returns:
- If the incense is used
-