Dev stuff is complete

This commit is contained in:
Cricket committed 2015-02-19 17:13:16 -05:00
1 parent 496ac181da
commit 530239fd72
9 files changed
+259 -530

No files matched your search

@@ -1,12 +1,10 @@
package com.cricketcraft.chisel.config;
import java.util.Locale;
import com.cricketcraft.chisel.Features;
import net.minecraftforge.common.config.Configuration;
import org.apache.commons.lang3.StringUtils;
import com.cricketcraft.chisel.Features;
import java.util.Locale;
public class Configurations {
@@ -39,10 +37,12 @@ public class Configurations {
public static boolean allowChiselDamage;
public static int ironChiselMaxDamage;
public static int diamondChiselMaxDamage;
public static int obsidianChiselMaxDamage;
public static boolean ironChiselCanLeftClick;
public static boolean ironChiselHasModes;
public static int ironChiselAttackDamage;
public static int diamondChiselAttackDamage;
public static int obsidianChiselAttackDamage;
public static boolean useRoadLineTool;
public static String getRoadLineTool;
@@ -63,7 +63,8 @@ public class Configurations {
chiselRecipe = config.get(category, "chiselAlternateRecipe", false, "Use alternative crafting recipe for the chisel").getBoolean(false);
enableFMP = config.get(category, "enableFMP", true, "Do you want to enable FMP").getBoolean(true);
chiselStoneToCobbleBricks = config.get(category, "chiselStoneToCobbleBricks", true, "Chisel stone to cobblestone and bricks by left clicking.").getBoolean(false);
chiselBackToVanillaLeaves = config.get(category, "chiselBackToVanillaLeaves", false, "If this is true, you can chisel from the chisel leaves back to vanilla ones. If it is false, you cannot.").getBoolean(false);
chiselBackToVanillaLeaves = config.get(category, "chiselBackToVanillaLeaves", false, "If this is true, you can chisel from the chisel leaves back to vanilla ones. If it is false, you cannot.")
.getBoolean(false);
/* worldgen */
category = "worldgen";
@@ -87,10 +88,15 @@ public class Configurations {
allowChiselDamage = config.get(category, "allowChiselDamage", true, "Should the chisel be damageable and take damage when it chisels something.").getBoolean();
ironChiselMaxDamage = config.get(category, "ironChiselMaxDamage", 500, "The max damage of the standard iron chisel. Default: 500.").getInt();
diamondChiselMaxDamage = config.get(category, "diamondChiselMaxDamage", 5000, "The max damage of the diamond chisel. Default: 5000").getInt();
obsidianChiselMaxDamage = config.get(category, "obsidianChiselMaxDamage", 50000, "The max damage of the obsidian chisel. Default: 50000").getInt();
ironChiselCanLeftClick = config.get(category, "ironChiselCanLeftClick", true, "If this is true, the iron chisel can left click chisel blocks. If false, it cannot.").getBoolean();
ironChiselHasModes = config.get(category, "ironChiselHasModes", false, "If this is true, the iron chisel can change its chisel mode just as the diamond chisel can.").getBoolean();
ironChiselAttackDamage = config.get(category, "ironChiselAttackDamage", 2, "The extra attack damage points (in half hearts) that the iron chisel inflicts when it is used to attack an entity.").getInt();
diamondChiselAttackDamage = config.get(category, "diamondChiselAttackDamage", 2, "The extra attack damage points (in half hearts) that the diamond chisel inflicts when it is used to attack an entity.").getInt();
ironChiselAttackDamage = config.get(category, "ironChiselAttackDamage", 2, "The extra attack damage points (in half hearts) that the iron chisel inflicts when it is used to attack an entity.")
.getInt();
diamondChiselAttackDamage = config
.get(category, "diamondChiselAttackDamage", 2, "The extra attack damage points (in half hearts) that the diamond chisel inflicts when it is used to attack an entity.").getInt();
obsidianChiselAttackDamage = config
.get(category, "obsidianChiselAttackDamage", 4, "The extra attack damage points (in half hearts) that the obsidian chisel inflicts when it is used to attack an entity.").getInt();
/* block */
category = "block";
@@ -110,7 +116,9 @@ public class Configurations {
return config.get("features", featureName(feature), true).getBoolean(true) && refreshConfig();
}
/** Makes the old camelCase names from the new CONSTANT_CASE names */
/**
* Makes the old camelCase names from the new CONSTANT_CASE names
*/
public static String featureName(Features feature) {
String[] words = feature.name().toLowerCase(Locale.ENGLISH).split("_");
if (words.length == 1) {