Search in sources :

Example 1 with Bee

use of forestry.apiculture.genetics.Bee in project ForestryMC by ForestryMC.

the class ItemInventoryImprinter method getSelectedBee.

public IBee getSelectedBee() {
    IBeeRoot beeRoot = BeeManager.beeRoot;
    List<IBee> individualTemplates = beeRoot.getIndividualTemplates();
    Map<String, IAllele[]> genomeTemplates = beeRoot.getGenomeTemplates();
    IAllele[] templateActive = genomeTemplates.get(individualTemplates.get(primaryIndex).getIdent());
    IAllele[] templateInactive = genomeTemplates.get(individualTemplates.get(secondaryIndex).getIdent());
    IBeeGenome genome = beeRoot.templateAsGenome(templateActive, templateInactive);
    return new Bee(genome);
}
Also used : IAllele(forestry.api.genetics.IAllele) IBee(forestry.api.apiculture.IBee) Bee(forestry.apiculture.genetics.Bee) IBeeRoot(forestry.api.apiculture.IBeeRoot) IBee(forestry.api.apiculture.IBee) IBeeGenome(forestry.api.apiculture.IBeeGenome)

Aggregations

IBee (forestry.api.apiculture.IBee)1 IBeeGenome (forestry.api.apiculture.IBeeGenome)1 IBeeRoot (forestry.api.apiculture.IBeeRoot)1 IAllele (forestry.api.genetics.IAllele)1 Bee (forestry.apiculture.genetics.Bee)1