Add config option to auto-truncate player skill levels that exceed the configured max level. Adds #2512

Also removes a good bit of magic numbering from FlatFileDatabaseManager
This commit is contained in:
t00thpick1
2015-11-12 19:10:09 -05:00
parent b966529487
commit f4b6d7845e
4 changed files with 236 additions and 116 deletions

View File

@ -528,6 +528,8 @@ public class Config extends AutoUpdateConfigLoader {
return (cap <= 0) ? Integer.MAX_VALUE : cap;
}
public boolean getTruncateSkills() { return config.getBoolean("General.TruncateSkills", false); }
/* PVP & PVE Settings */
public boolean getPVPEnabled(SkillType skill) { return config.getBoolean("Skills." + StringUtils.getCapitalized(skill.toString()) + ".Enabled_For_PVP", true); }
public boolean getPVEEnabled(SkillType skill) { return config.getBoolean("Skills." + StringUtils.getCapitalized(skill.toString()) + ".Enabled_For_PVE", true); }