mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-23 05:36:46 +01:00
Update Herbalism to alphabetical order
This commit is contained in:
parent
0cd23c1b65
commit
40a13c4c81
@ -41,11 +41,12 @@ public class HerbalismCommand extends SkillCommand {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void dataCalculations(Player player, float skillValue, boolean isLucky) {
|
protected void dataCalculations(Player player, float skillValue, boolean isLucky) {
|
||||||
// GREEN TERRA
|
|
||||||
if (canGreenTerra) {
|
// DOUBLE DROPS
|
||||||
String[] greenTerraStrings = calculateLengthDisplayValues(player, skillValue);
|
if (canDoubleDrop) {
|
||||||
greenTerraLength = greenTerraStrings[0];
|
String[] doubleDropStrings = calculateAbilityDisplayValues(skillValue, SubSkillType.HERBALISM_DOUBLE_DROPS, isLucky);
|
||||||
greenTerraLengthEndurance = greenTerraStrings[1];
|
doubleDropChance = doubleDropStrings[0];
|
||||||
|
doubleDropChanceLucky = doubleDropStrings[1];
|
||||||
}
|
}
|
||||||
|
|
||||||
// FARMERS DIET
|
// FARMERS DIET
|
||||||
@ -53,6 +54,13 @@ public class HerbalismCommand extends SkillCommand {
|
|||||||
farmersDietRank = RankUtils.getRank(player, SubSkillType.HERBALISM_FARMERS_DIET);
|
farmersDietRank = RankUtils.getRank(player, SubSkillType.HERBALISM_FARMERS_DIET);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// GREEN TERRA
|
||||||
|
if (canGreenTerra) {
|
||||||
|
String[] greenTerraStrings = calculateLengthDisplayValues(player, skillValue);
|
||||||
|
greenTerraLength = greenTerraStrings[0];
|
||||||
|
greenTerraLengthEndurance = greenTerraStrings[1];
|
||||||
|
}
|
||||||
|
|
||||||
// GREEN THUMB
|
// GREEN THUMB
|
||||||
if (canGreenThumbBlocks || canGreenThumbPlants) {
|
if (canGreenThumbBlocks || canGreenThumbPlants) {
|
||||||
greenThumbStage = RankUtils.getRank(player, SubSkillType.HERBALISM_GREEN_THUMB);
|
greenThumbStage = RankUtils.getRank(player, SubSkillType.HERBALISM_GREEN_THUMB);
|
||||||
@ -62,13 +70,6 @@ public class HerbalismCommand extends SkillCommand {
|
|||||||
greenThumbChanceLucky = greenThumbStrings[1];
|
greenThumbChanceLucky = greenThumbStrings[1];
|
||||||
}
|
}
|
||||||
|
|
||||||
// DOUBLE DROPS
|
|
||||||
if (canDoubleDrop) {
|
|
||||||
String[] doubleDropStrings = calculateAbilityDisplayValues(skillValue, SubSkillType.HERBALISM_DOUBLE_DROPS, isLucky);
|
|
||||||
doubleDropChance = doubleDropStrings[0];
|
|
||||||
doubleDropChanceLucky = doubleDropStrings[1];
|
|
||||||
}
|
|
||||||
|
|
||||||
// HYLIAN LUCK
|
// HYLIAN LUCK
|
||||||
if (hasHylianLuck) {
|
if (hasHylianLuck) {
|
||||||
String[] hylianLuckStrings = calculateAbilityDisplayValues(skillValue, SubSkillType.HERBALISM_HYLIAN_LUCK, isLucky);
|
String[] hylianLuckStrings = calculateAbilityDisplayValues(skillValue, SubSkillType.HERBALISM_HYLIAN_LUCK, isLucky);
|
||||||
@ -99,6 +100,15 @@ public class HerbalismCommand extends SkillCommand {
|
|||||||
protected List<String> statsDisplay(Player player, float skillValue, boolean hasEndurance, boolean isLucky) {
|
protected List<String> statsDisplay(Player player, float skillValue, boolean hasEndurance, boolean isLucky) {
|
||||||
List<String> messages = new ArrayList<String>();
|
List<String> messages = new ArrayList<String>();
|
||||||
|
|
||||||
|
if (canDoubleDrop) {
|
||||||
|
messages.add(getStatMessage(SubSkillType.HERBALISM_DOUBLE_DROPS, doubleDropChance)
|
||||||
|
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", doubleDropChanceLucky) : ""));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (canFarmersDiet) {
|
||||||
|
messages.add(getStatMessage(false, true, SubSkillType.HERBALISM_FARMERS_DIET, String.valueOf(farmersDietRank)));
|
||||||
|
}
|
||||||
|
|
||||||
if (canGreenTerra) {
|
if (canGreenTerra) {
|
||||||
messages.add(getStatMessage(SubSkillType.HERBALISM_GREEN_TERRA, greenTerraLength)
|
messages.add(getStatMessage(SubSkillType.HERBALISM_GREEN_TERRA, greenTerraLength)
|
||||||
+ (hasEndurance ? LocaleLoader.getString("Perks.ActivationTime.Bonus", greenTerraLengthEndurance) : ""));
|
+ (hasEndurance ? LocaleLoader.getString("Perks.ActivationTime.Bonus", greenTerraLengthEndurance) : ""));
|
||||||
@ -116,10 +126,6 @@ public class HerbalismCommand extends SkillCommand {
|
|||||||
messages.add(getStatMessage(true, true,SubSkillType.HERBALISM_GREEN_THUMB, String.valueOf(greenThumbStage)));
|
messages.add(getStatMessage(true, true,SubSkillType.HERBALISM_GREEN_THUMB, String.valueOf(greenThumbStage)));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (canFarmersDiet) {
|
|
||||||
messages.add(getStatMessage(false, true, SubSkillType.HERBALISM_FARMERS_DIET, String.valueOf(farmersDietRank)));
|
|
||||||
}
|
|
||||||
|
|
||||||
if (hasHylianLuck) {
|
if (hasHylianLuck) {
|
||||||
messages.add(getStatMessage(SubSkillType.HERBALISM_HYLIAN_LUCK, hylianLuckChance)
|
messages.add(getStatMessage(SubSkillType.HERBALISM_HYLIAN_LUCK, hylianLuckChance)
|
||||||
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", hylianLuckChanceLucky) : ""));
|
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", hylianLuckChanceLucky) : ""));
|
||||||
@ -130,11 +136,6 @@ public class HerbalismCommand extends SkillCommand {
|
|||||||
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", shroomThumbChanceLucky) : ""));
|
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", shroomThumbChanceLucky) : ""));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (canDoubleDrop) {
|
|
||||||
messages.add(getStatMessage(SubSkillType.HERBALISM_DOUBLE_DROPS, doubleDropChance)
|
|
||||||
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", doubleDropChanceLucky) : ""));
|
|
||||||
}
|
|
||||||
|
|
||||||
return messages;
|
return messages;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user