Search in sources :

Example 1 with IFieldKitPlugin

use of binnie.core.api.genetics.IFieldKitPlugin in project Binnie by ForestryMC.

the class ControlChromosome method setSystem.

public void setSystem(@Nullable IBreedingSystem breedingSystem) {
    if (this.breedingSystem != breedingSystem) {
        this.breedingSystem = breedingSystem;
        deleteAllChildren();
        if (breedingSystem != null) {
            IFieldKitPlugin fieldKitPlugin = breedingSystem.getFieldKitPlugin();
            fieldKitPlugin.getChromosomePickerPositions();
            for (Map.Entry<IChromosomeType, IPoint> entry : fieldKitPlugin.getChromosomePickerPositions().entrySet()) {
                IChromosomeType chromosomeType = entry.getKey();
                IPoint position = entry.getValue();
                new ControlChromoPicker(this, position.xPos(), position.yPos(), chromosomeType);
            }
        }
    }
}
Also used : IFieldKitPlugin(binnie.core.api.genetics.IFieldKitPlugin) IPoint(binnie.core.api.gui.IPoint) IChromosomeType(forestry.api.genetics.IChromosomeType) Map(java.util.Map)

Aggregations

IFieldKitPlugin (binnie.core.api.genetics.IFieldKitPlugin)1 IPoint (binnie.core.api.gui.IPoint)1 IChromosomeType (forestry.api.genetics.IChromosomeType)1 Map (java.util.Map)1