本文整理汇总了Java中forestry.api.genetics.IAlleleTolerance类的典型用法代码示例。如果您正苦于以下问题:Java IAlleleTolerance类的具体用法?Java IAlleleTolerance怎么用?Java IAlleleTolerance使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IAlleleTolerance类属于forestry.api.genetics包,在下文中一共展示了IAlleleTolerance类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: addAlleleInfo
import forestry.api.genetics.IAlleleTolerance; //导入依赖的package包/类
@Override
protected void addAlleleInfo(GenomeAccess access, Map<String, Object> result) {
result.put("species", convertAllele(access, IAlleleSpecies.class, EnumBeeChromosome.SPECIES));
result.put("speed", convertAllele(access, IAlleleFloat.class, EnumBeeChromosome.SPEED));
result.put("lifespan", convertAllele(access, IAlleleInteger.class, EnumBeeChromosome.LIFESPAN));
result.put("fertility", convertAllele(access, IAlleleInteger.class, EnumBeeChromosome.FERTILITY));
result.put("temperatureTolerance", convertAllele(access, IAlleleTolerance.class, EnumBeeChromosome.TEMPERATURE_TOLERANCE));
result.put("nocturnal", convertAllele(access, IAlleleBoolean.class, EnumBeeChromosome.NOCTURNAL));
result.put("humidityTolerance", convertAllele(access, IAlleleTolerance.class, EnumBeeChromosome.HUMIDITY_TOLERANCE));
result.put("tolerantFlyer", convertAllele(access, IAlleleBoolean.class, EnumBeeChromosome.TOLERANT_FLYER));
result.put("caveDwelling", convertAllele(access, IAlleleBoolean.class, EnumBeeChromosome.CAVE_DWELLING));
result.put("flowerProvider", convertAllele(access, IAlleleFlowers.class, EnumBeeChromosome.FLOWER_PROVIDER));
result.put("flowering", convertAllele(access, IAlleleInteger.class, EnumBeeChromosome.FLOWERING));
result.put("effect", convertAllele(access, IAlleleBeeEffect.class, EnumBeeChromosome.EFFECT));
result.put("territory", convertAllele(access, IAlleleArea.class, EnumBeeChromosome.TERRITORY));
}
开发者ID:OpenMods,项目名称:OpenPeripheral-Integration,代码行数:17,代码来源:ConverterIIndividual.java
示例2: canWorkInTemperature
import forestry.api.genetics.IAlleleTolerance; //导入依赖的package包/类
public boolean canWorkInTemperature(EnumTemperature temp) {
IAlleleTolerance tolerance = (IAlleleTolerance) genomeTemplate[EnumBeeChromosome.TEMPERATURE_TOLERANCE.ordinal()];
return AlleleManager.climateHelper
.isWithinLimits(temp, EnumHumidity.NORMAL, temperature, tolerance.getValue(), EnumHumidity.NORMAL, EnumTolerance.NONE);
}
开发者ID:MagicBees,项目名称:MagicBees,代码行数:6,代码来源:BeeSpecies.java
示例3: canWorkInHumidity
import forestry.api.genetics.IAlleleTolerance; //导入依赖的package包/类
public boolean canWorkInHumidity(EnumHumidity humid) {
IAlleleTolerance tolerance = (IAlleleTolerance) genomeTemplate[EnumBeeChromosome.HUMIDITY_TOLERANCE.ordinal()];
return AlleleManager.climateHelper.isWithinLimits(EnumTemperature.NORMAL, humid, EnumTemperature.NORMAL, EnumTolerance.NONE, humidity,
tolerance.getValue());
}
开发者ID:MagicBees,项目名称:MagicBees,代码行数:6,代码来源:BeeSpecies.java
注:本文中的forestry.api.genetics.IAlleleTolerance类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论