diff --git a/Changelog.txt b/Changelog.txt index 8640fd27b..24e3337d3 100644 --- a/Changelog.txt +++ b/Changelog.txt @@ -169,6 +169,7 @@ Version 2.2.0 Added API method to grab the level cap of a skill by its PrimarySkillType ENUM definition Added API method to check if a skill was being level capped Added 'UndefinedSkillBehaviour' for trying to use a method that has no behaviour defined for the provided skill + Version 2.1.81 Fixed a bug where Arrow Deflect would never trigger outside of PVP Fixed a bug where failing to salvage enchantments incorrectly colored the text diff --git a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalism.java b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalism.java index c1312980b..295b57324 100644 --- a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalism.java +++ b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalism.java @@ -1,5 +1,6 @@ package com.gmail.nossr50.config.hocon.skills.herbalism; +import com.gmail.nossr50.config.ConfigConstants; import ninja.leaping.configurate.objectmapping.Setting; import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable; @@ -53,8 +54,30 @@ public class ConfigHerbalism { "\nHerbalism and other gathering skills offer a chance to get extra drops when harvesting the block.") private HashSet herbalismDoubleDropWhiteList = DEFAULT_BONUS_DROPS; + @Setting(value = ConfigConstants.SUB_SKILL_NODE) + private ConfigHerbalismSubSkills configHerbalismSubSkills = new ConfigHerbalismSubSkills(); + public HashSet getBonusDrops() { return herbalismDoubleDropWhiteList; } + public ConfigHerbalismSubSkills getConfigHerbalismSubSkills() { + return configHerbalismSubSkills; + } + + public ConfigHerbalismDoubleDrops getDoubleDrops() { + return configHerbalismSubSkills.getDoubleDrops(); + } + + public ConfigHerbalismGreenThumb getGreenThumb() { + return configHerbalismSubSkills.getGreenThumb(); + } + + public ConfigHerbalismHylianLuck getHylianLuck() { + return configHerbalismSubSkills.getHylianLuck(); + } + + public ConfigHerbalismShroomThumb getShroomThumb() { + return configHerbalismSubSkills.getShroomThumb(); + } } \ No newline at end of file diff --git a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismDoubleDrops.java b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismDoubleDrops.java new file mode 100644 index 000000000..35d254ee6 --- /dev/null +++ b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismDoubleDrops.java @@ -0,0 +1,18 @@ +package com.gmail.nossr50.config.hocon.skills.herbalism; + +import com.gmail.nossr50.config.ConfigConstants; +import com.gmail.nossr50.datatypes.skills.properties.AbstractMaxBonusLevel; +import com.gmail.nossr50.datatypes.skills.properties.MaxBonusLevel; +import ninja.leaping.configurate.objectmapping.Setting; +import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable; + +@ConfigSerializable +public class ConfigHerbalismDoubleDrops { + + @Setting(value = ConfigConstants.MAX_CHANCE_FIELD_NAME, comment = ConfigConstants.MAX_CHANCE_FIELD_DESCRIPTION) + private double maxChance = 100.0; + + @Setting(value = ConfigConstants.MAX_BONUS_LEVEL_FIELD_NAME) + private MaxBonusLevel maxBonusLevel = new AbstractMaxBonusLevel(100); + +} diff --git a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismGreenThumb.java b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismGreenThumb.java new file mode 100644 index 000000000..9ae5f8a94 --- /dev/null +++ b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismGreenThumb.java @@ -0,0 +1,18 @@ +package com.gmail.nossr50.config.hocon.skills.herbalism; + +import com.gmail.nossr50.config.ConfigConstants; +import com.gmail.nossr50.datatypes.skills.properties.AbstractMaxBonusLevel; +import com.gmail.nossr50.datatypes.skills.properties.MaxBonusLevel; +import ninja.leaping.configurate.objectmapping.Setting; +import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable; + +@ConfigSerializable +public class ConfigHerbalismGreenThumb { + + @Setting(value = ConfigConstants.MAX_CHANCE_FIELD_NAME, comment = ConfigConstants.MAX_CHANCE_FIELD_DESCRIPTION) + private double maxChance = 100.0; + + @Setting(value = ConfigConstants.MAX_BONUS_LEVEL_FIELD_NAME) + private MaxBonusLevel maxBonusLevel = new AbstractMaxBonusLevel(100); + +} diff --git a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismHylianLuck.java b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismHylianLuck.java new file mode 100644 index 000000000..830e2f824 --- /dev/null +++ b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismHylianLuck.java @@ -0,0 +1,18 @@ +package com.gmail.nossr50.config.hocon.skills.herbalism; + +import com.gmail.nossr50.config.ConfigConstants; +import com.gmail.nossr50.datatypes.skills.properties.AbstractMaxBonusLevel; +import com.gmail.nossr50.datatypes.skills.properties.MaxBonusLevel; +import ninja.leaping.configurate.objectmapping.Setting; +import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable; + +@ConfigSerializable +public class ConfigHerbalismHylianLuck { + + @Setting(value = ConfigConstants.MAX_CHANCE_FIELD_NAME, comment = ConfigConstants.MAX_CHANCE_FIELD_DESCRIPTION) + private double maxChance = 10.0; + + @Setting(value = ConfigConstants.MAX_BONUS_LEVEL_FIELD_NAME) + private MaxBonusLevel maxBonusLevel = new AbstractMaxBonusLevel(100); + +} diff --git a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismShroomThumb.java b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismShroomThumb.java new file mode 100644 index 000000000..8e4fce6a4 --- /dev/null +++ b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismShroomThumb.java @@ -0,0 +1,18 @@ +package com.gmail.nossr50.config.hocon.skills.herbalism; + +import com.gmail.nossr50.config.ConfigConstants; +import com.gmail.nossr50.datatypes.skills.properties.AbstractMaxBonusLevel; +import com.gmail.nossr50.datatypes.skills.properties.MaxBonusLevel; +import ninja.leaping.configurate.objectmapping.Setting; +import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable; + +@ConfigSerializable +public class ConfigHerbalismShroomThumb { + + @Setting(value = ConfigConstants.MAX_CHANCE_FIELD_NAME, comment = ConfigConstants.MAX_CHANCE_FIELD_DESCRIPTION) + private double maxChance = 50.0; + + @Setting(value = ConfigConstants.MAX_BONUS_LEVEL_FIELD_NAME) + private MaxBonusLevel maxBonusLevel = new AbstractMaxBonusLevel(100); + +} diff --git a/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismSubSkills.java b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismSubSkills.java new file mode 100644 index 000000000..fbf684ce9 --- /dev/null +++ b/src/main/java/com/gmail/nossr50/config/hocon/skills/herbalism/ConfigHerbalismSubSkills.java @@ -0,0 +1,37 @@ +package com.gmail.nossr50.config.hocon.skills.herbalism; + +import ninja.leaping.configurate.objectmapping.Setting; +import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable; + +@ConfigSerializable +public class ConfigHerbalismSubSkills { + + @Setting(value = "Double-Drops") + private ConfigHerbalismDoubleDrops doubleDrops = new ConfigHerbalismDoubleDrops(); + + @Setting(value = "Green-Thumb") + private ConfigHerbalismGreenThumb greenThumb = new ConfigHerbalismGreenThumb(); + + @Setting(value = "Hylian-Luck") + private ConfigHerbalismHylianLuck hylianLuck = new ConfigHerbalismHylianLuck(); + + @Setting(value = "Shroom-Thumb") + private ConfigHerbalismShroomThumb shroomThumb = new ConfigHerbalismShroomThumb(); + + + public ConfigHerbalismDoubleDrops getDoubleDrops() { + return doubleDrops; + } + + public ConfigHerbalismGreenThumb getGreenThumb() { + return greenThumb; + } + + public ConfigHerbalismHylianLuck getHylianLuck() { + return hylianLuck; + } + + public ConfigHerbalismShroomThumb getShroomThumb() { + return shroomThumb; + } +}