Package forestry.api.plugin
Interface ISpeciesTypeBuilder
public interface ISpeciesTypeBuilder
Used to define the karyotype, life stages, and research materials for a new type of species.
The karyotype is the most important piece here, determining how genomes are structured.
This includes which chromosomes are allowed, which alleles those chromosomes can have,
the default alleles for those chromosomes, and most importantly, the species chromosome.
-
Method Summary
Modifier and TypeMethodDescriptionaddResearchMaterials(Consumer<it.unimi.dsi.fastutil.objects.Reference2FloatMap<net.minecraft.world.item.Item>> materials) Allows adding new Escritoire research materials or removing the default ones.addStages(ILifeStage... stages) Adds possible life stages to this species type.voidbuildResearchMaterials(it.unimi.dsi.fastutil.objects.Reference2FloatMap<net.minecraft.world.item.Item> materialMap) setDefaultStage(ILifeStage stage) Sets the default life stage of this species type.setKaryotype(Consumer<IKaryotypeBuilder> karyotype) Defines the default karyotype for members of this species type.
-
Method Details
-
setKaryotype
Defines the default karyotype for members of this species type. Although the default genome can be customized on a per-species basis, all members of the same species type have the same set of chromosomes. Multiple calls to this method will be chained and can override results of previous calls. -
addStages
Adds possible life stages to this species type. Make sure to also callsetDefaultStage(forestry.api.genetics.ILifeStage). -
addResearchMaterials
ISpeciesTypeBuilder addResearchMaterials(Consumer<it.unimi.dsi.fastutil.objects.Reference2FloatMap<net.minecraft.world.item.Item>> materials) Allows adding new Escritoire research materials or removing the default ones. -
setDefaultStage
Sets the default life stage of this species type.- Parameters:
stage- The default stage for use in menus.
-
getDefaultStage
-
getStages
-
buildResearchMaterials
@Internal void buildResearchMaterials(it.unimi.dsi.fastutil.objects.Reference2FloatMap<net.minecraft.world.item.Item> materialMap)
-