Wire up salvage config options

This commit is contained in:
nossr50 2019-06-16 09:12:42 -07:00
parent 303b12b79f
commit 3a89ba2139
2 changed files with 2 additions and 11 deletions

View File

@ -173,15 +173,6 @@ public class AdvancedConfig extends ConfigValidated {
return getDoubleValue(SKILLS, FISHING, MASTER_ANGLER, BIOME_MODIFIER); return getDoubleValue(SKILLS, FISHING, MASTER_ANGLER, BIOME_MODIFIER);
} }
/* MINING */
public double getArcaneSalvageExtractFullEnchantsChance(int rank) {
return getDoubleValue(SKILLS, SALVAGE, ARCANE_SALVAGE, EXTRACT_FULL_ENCHANT, RANK, String.valueOf(rank));
}
public double getArcaneSalvageExtractPartialEnchantsChance(int rank) {
return getDoubleValue(SKILLS, SALVAGE, ARCANE_SALVAGE, EXTRACT_PARTIAL_ENCHANT, RANK, String.valueOf(rank));
}
/* SWORDS */ /* SWORDS */
public double getRuptureDamagePlayer() { public double getRuptureDamagePlayer() {
return getDoubleValue(SKILLS, SWORDS, RUPTURE, DAMAGE_PLAYER); return getDoubleValue(SKILLS, SWORDS, RUPTURE, DAMAGE_PLAYER);

View File

@ -200,11 +200,11 @@ public class SalvageManager extends SkillManager {
if (Permissions.hasSalvageEnchantBypassPerk(getPlayer())) if (Permissions.hasSalvageEnchantBypassPerk(getPlayer()))
return 100.0D; return 100.0D;
return AdvancedConfig.getInstance().getArcaneSalvageExtractFullEnchantsChance(getArcaneSalvageRank()); return mcMMO.getConfigManager().getConfigSalvage().getConfigArcaneSalvage().getExtractFullEnchantChance().get(getArcaneSalvageRank());
} }
public double getExtractPartialEnchantChance() { public double getExtractPartialEnchantChance() {
return AdvancedConfig.getInstance().getArcaneSalvageExtractPartialEnchantsChance(getArcaneSalvageRank()); return mcMMO.getConfigManager().getConfigSalvage().getConfigArcaneSalvage().getExtractPartialEnchantChance().get(getArcaneSalvageRank());
} }
private ItemStack arcaneSalvageCheck(Map<Enchantment, Integer> enchants) { private ItemStack arcaneSalvageCheck(Map<Enchantment, Integer> enchants) {