From fd7f2aa2ff9e7c58a9dcaab23a1d11fe81f159b0 Mon Sep 17 00:00:00 2001 From: Adubbz Date: Sun, 12 May 2013 10:04:26 +1000 Subject: [PATCH] Tweaked the cloud collision box, made the sky colour of the Promised Land Biomes configurable, prevented fall damage if landing on a cloud --- .../biomes/BiomeGenPromisedLandForest.java | 2 +- .../biomes/BiomeGenPromisedLandPlains.java | 2 +- .../biomes/BiomeGenPromisedLandSwamp.java | 2 +- src/minecraft/biomesoplenty/blocks/BlockCloud.java | 3 ++- .../configuration/BOPConfiguration.java | 13 ++++++++++++- 5 files changed, 17 insertions(+), 5 deletions(-) diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandForest.java b/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandForest.java index 51ff271e4..9538036dc 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandForest.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandForest.java @@ -91,7 +91,7 @@ public class BiomeGenPromisedLandForest extends BiomeGenBase { if (BOPConfiguration.skyColors = true) { - return 50175; + return BOPConfiguration.pLForestSkyColour; } else { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandPlains.java b/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandPlains.java index c084a32b0..6005ffccb 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandPlains.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandPlains.java @@ -90,7 +90,7 @@ public class BiomeGenPromisedLandPlains extends BiomeGenBase { if (BOPConfiguration.skyColors = true) { - return 50175; + return BOPConfiguration.pLPlainsSkyColour; } else { diff --git a/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandSwamp.java b/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandSwamp.java index 0c92b260a..4cc92d674 100644 --- a/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandSwamp.java +++ b/src/minecraft/biomesoplenty/biomes/BiomeGenPromisedLandSwamp.java @@ -91,7 +91,7 @@ public class BiomeGenPromisedLandSwamp extends BiomeGenBase { if (BOPConfiguration.skyColors = true) { - return 50175; + return BOPConfiguration.pLSwampSkyColour; } else { diff --git a/src/minecraft/biomesoplenty/blocks/BlockCloud.java b/src/minecraft/biomesoplenty/blocks/BlockCloud.java index bdf7273d7..4181cfcfa 100644 --- a/src/minecraft/biomesoplenty/blocks/BlockCloud.java +++ b/src/minecraft/biomesoplenty/blocks/BlockCloud.java @@ -32,7 +32,7 @@ public class BlockCloud extends Block */ public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int par2, int par3, int par4) { - float var5 = 0.125F; + float var5 = 0.500F; return AxisAlignedBB.getAABBPool().getAABB((double)par2, (double)par3, (double)par4, (double)(par2 + 1), (double)((float)(par3 + 1) - var5), (double)(par4 + 1)); } @@ -41,6 +41,7 @@ public class BlockCloud extends Block */ public void onEntityCollidedWithBlock(World par1World, int par2, int par3, int par4, Entity par5Entity) { + par5Entity.fallDistance = 0.0F; par5Entity.motionX *= 0.8D; par5Entity.motionZ *= 0.8D; } diff --git a/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java b/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java index e0c589c3a..7f11aeca8 100644 --- a/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java +++ b/src/minecraft/biomesoplenty/configuration/BOPConfiguration.java @@ -20,6 +20,10 @@ public class BOPConfiguration { public static int villageDistance; public static int promisedLandDimID; + + public static int pLSwampSkyColour; + public static int pLPlainsSkyColour; + public static int pLForestSkyColour; public static boolean alpsGen; public static boolean arcticGen; @@ -406,7 +410,6 @@ public class BOPConfiguration { { config.load(); - skyColors = true; biomeSize = config.get("Biomes O\' Plenty World Type Settings", "Biome Size", 4, "Default World Type has 4. Large Biomes World Type has 6.").getInt(); achievements = config.get("Achievement Settings", "Add Biomes O\' Plenty Achievements", true).getBoolean(false); vanillaEnhanced = config.get("Biome Settings", "Enhanced Vanilla Biomes", true).getBoolean(false); @@ -417,7 +420,15 @@ public class BOPConfiguration { villageDistance = config.get("Biomes O\' Plenty World Type Settings", "Distance between villages", 32, "In Vanilla it is set to 32").getInt(); if (villageDistance < 8) villageDistance = 8; + + //Sky colour + skyColors = config.get("Sky Colours", "Enable Sky Colours", true).getBoolean(false); + + pLSwampSkyColour = config.get("Sky Colours", "Promised Land Swamp Sky Colour", 50175, null).getInt(); + pLPlainsSkyColour = config.get("Sky Colours", "Promised Land Plains Sky Colour", 50175, null).getInt(); + pLForestSkyColour = config.get("Sky Colours", "Promised Land Forest Sky Colour", 50175, null).getInt(); + //Biome generation alpsGen = config.get("Biomes To Generate", "Alps", true).getBoolean(false); arcticGen = config.get("Biomes To Generate", "Arctic", true).getBoolean(false); badlandsGen = config.get("Biomes To Generate", "Badlands", true).getBoolean(false);