mirror of
https://github.com/GTNewHorizons/ForestryMC.git
synced 2026-11-28 07:35:47 +00:00
Change the biome temperature and rainfall to ForestryAPI.climateManager.getTemperature and ForestryAPI.climateManager.getHumidity
This commit is contained in:
1 parent
336d388b4b
commit
806b5121a8
15 files changed
+46
-42
No files matched your search
@@ -7,6 +7,7 @@ package forestry.api.core;
|
||||
|
||||
import net.minecraft.client.renderer.texture.TextureAtlasSprite;
|
||||
import net.minecraft.util.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.biome.BiomeGenBase;
|
||||
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
@@ -66,11 +67,11 @@ public enum EnumTemperature {
|
||||
return getFromValue(biomeGenBase.temperature);
|
||||
}
|
||||
|
||||
public static EnumTemperature getFromBiome(BiomeGenBase biomeGenBase, BlockPos pos) {
|
||||
public static EnumTemperature getFromBiome(BiomeGenBase biomeGenBase, World world, BlockPos pos) {
|
||||
if (BiomeHelper.isBiomeHellish(biomeGenBase)) {
|
||||
return HELLISH;
|
||||
}
|
||||
float temperature = biomeGenBase.getFloatTemperature(pos);
|
||||
float temperature = ForestryAPI.climateManager.getTemperature(world, pos);
|
||||
return getFromValue(temperature);
|
||||
}
|
||||
}
|
||||
@@ -26,10 +26,4 @@ public interface IGreenhouseHousing extends IErrorLogicSource {
|
||||
*/
|
||||
World getWorld();
|
||||
|
||||
|
||||
/**
|
||||
* @return Is the position in the greenhouse
|
||||
*/
|
||||
boolean isInGreenhouse(BlockPos pos);
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user