Skip to content
Permalink
Browse files

switch short grass and mycelium separately in config

  • Loading branch information...
octarine-noise committed Mar 11, 2015
1 parent 711f93a commit 4fbf771f04adedb96c9c96d5af9b428db8c2e6ce
@@ -25,7 +25,7 @@
public IconSet myceliumIcons = new IconSet("bettergrassandleaves", "better_mycel_%d");

public boolean isBlockAccepted(IBlockAccess blockAccess, int x, int y, int z, Block block, int original) {
if (!Config.grassEnabled) return false;
if (!Config.myceliumEnabled) return false;
if (block != Blocks.mycelium) return false;
if (!blockAccess.isAirBlock(x, y + 1, z) && blockAccess.getBlock(x, y + 1, z) != Blocks.snow_layer) return false;
return true;
@@ -53,6 +53,7 @@
public static double grassHeightMax;
public static double grassSize;
public static boolean grassShaderWind;
public static boolean myceliumEnabled;

public static boolean cactusEnabled;

@@ -142,14 +143,15 @@ public static void updateValues() {
leavesVOffset = getDouble(Category.extraLeaves, "vOffset", 0.1, 0.0, 0.4, "betterfoliage.vOffset");
leavesSize = getDouble(Category.extraLeaves, "size", 1.4, 0.75, 2.5, "betterfoliage.size");

grassEnabled = getBoolean(Category.shortGrass, "enabled", true, "betterfoliage.enabled");
grassEnabled = getBoolean(Category.shortGrass, "enabled", true, "betterfoliage.shortGrass.grassEnabled");
grassHOffset = getDouble(Category.shortGrass, "hOffset", 0.2, 0.0, 0.4, "betterfoliage.hOffset");
grassHeightMin = getDouble(Category.shortGrass, "heightMin", 0.6, 0.1, 2.5, "betterfoliage.minHeight");
grassHeightMax = getDouble(Category.shortGrass, "heightMax", 0.8, 0.1, 2.5, "betterfoliage.maxHeight");
grassSize = getDouble(Category.shortGrass, "size", 1.0, 0.5, 1.5, "betterfoliage.size");
grassUseGenerated = getBoolean(Category.shortGrass, "useGenerated", false, "betterfoliage.shortGrass.useGenerated");
grassHeightMin = clampDoubleToMax(Category.shortGrass, "heightMin", "heightMax");
grassShaderWind = getBoolean(Category.shortGrass, "shaderWind", true, "betterfoliage.shaderWind");
myceliumEnabled = getBoolean(Category.shortGrass, "myceliumEnabled", true, "betterfoliage.shortGrass.myceliumEnabled");

cactusEnabled = getBoolean(Category.cactus, "enabled", true, "betterfoliage.enabled");

@@ -238,7 +240,7 @@ public static void updateValues() {
for (Category category : Category.values()) rawConfig.setCategoryLanguageKey(category.toString(), String.format("betterfoliage.%s", category.toString()));

setOrder(Category.extraLeaves, "enabled", "skewMode", "hOffset", "vOffset", "size");
setOrder(Category.shortGrass, "enabled", "useGenerated", "hOffset", "heightMin", "heightMax", "size", "shaderWind");
setOrder(Category.shortGrass, "enabled", "myceliumEnabled", "useGenerated", "hOffset", "heightMin", "heightMax", "size", "shaderWind");
setOrder(Category.lilypad, "enabled", "hOffset", "flowerChance");
setOrder(Category.reed, "enabled", "hOffset", "heightMin", "heightMax", "population", "biomeList", "shaderWind");
setOrder(Category.algae, "enabled", "hOffset", "heightMin", "heightMax", "size", "population", "biomeList");
@@ -49,10 +49,14 @@ betterfoliage.leavesMode.tooltip=Translate draws the leaves off-center at a 45de
betterfoliage.leavesMode.true=Skew
betterfoliage.leavesMode.false=Translate

betterfoliage.shortGrass=Short Grass
betterfoliage.shortGrass.tooltip=Tufts of grass on top of grass blocks
betterfoliage.shortGrass.useGenerated=Use generated texture
betterfoliage.shortGrass=Short Grass & Mycelium
betterfoliage.shortGrass.tooltip=Tufts of grass/mycelium on top of appropriate blocks
betterfoliage.shortGrass.useGenerated=Use generated texture for grass
betterfoliage.shortGrass.useGenerated.tooltip=Generated texture is made by slicing the tallgrass texture from the active resource pack in half
betterfoliage.shortGrass.myceliumEnabled=Enable Mycelium
betterfoliage.shortGrass.myceliumEnabled.tooltip=Is this feature enabled for mycelium blocks?
betterfoliage.shortGrass.grassEnabled=Enable Grass
betterfoliage.shortGrass.grassEnabled.tooltip=Is this feature enabled for grass blocks?

betterfoliage.cactus=Better Cactus
betterfoliage.cactus.tooltip=Enhance cactus with extra bits and smooth shading

0 comments on commit 4fbf771

Please sign in to comment.
You can’t perform that action at this time.