aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/de
diff options
context:
space:
mode:
authorCow <cow@volloeko.de>2021-04-24 14:32:14 +0200
committerCow <cow@volloeko.de>2021-04-24 14:32:14 +0200
commitcabcf4201311afd9a6f05952b5acf03166cff0c8 (patch)
tree9ea3fbeb308d1089baa8f3229350882afdd931e9 /src/main/java/de
parent94517b10f9a005e9996b4d8a6c831eed80c958b4 (diff)
downloadCowlection-cabcf4201311afd9a6f05952b5acf03166cff0c8.tar.gz
Cowlection-cabcf4201311afd9a6f05952b5acf03166cff0c8.tar.bz2
Cowlection-cabcf4201311afd9a6f05952b5acf03166cff0c8.zip
Added config option to hide Gear Score separately
Diffstat (limited to 'src/main/java/de')
-rw-r--r--src/main/java/de/cowtipper/cowlection/config/MooConfig.java6
-rw-r--r--src/main/java/de/cowtipper/cowlection/listener/skyblock/DungeonsListener.java13
2 files changed, 17 insertions, 2 deletions
diff --git a/src/main/java/de/cowtipper/cowlection/config/MooConfig.java b/src/main/java/de/cowtipper/cowlection/config/MooConfig.java
index 27f12e7..5006953 100644
--- a/src/main/java/de/cowtipper/cowlection/config/MooConfig.java
+++ b/src/main/java/de/cowtipper/cowlection/config/MooConfig.java
@@ -94,6 +94,7 @@ public class MooConfig {
// Category: SkyBlock Dungeons
private static String showItemQualityAndFloor;
private static String dungItemQualityPos;
+ public static boolean dungItemHideGearScore;
public static int dungItemToolTipToggleKeyBinding;
public static boolean dungSendPerformanceOnDeath;
public static boolean dungOverlayEnabled;
@@ -503,6 +504,9 @@ public class MooConfig {
MooConfigPreview.createDungeonItem("light", "7/17/20 7:22 PM", "§7Gear Score: §d336 §8(526)", "§7Crit Chance: §c+5% §9(Light +2%)", "§7Crit Damage: §c+30% §9(Light +4%) §8(+48.9%)", "§7Bonus Attack Speed: §c+4% §9(Light +4%)", "", "§7Health: §a+126 HP §9(Light +15 HP) §8(+205.38 HP)", "§7Defense: §a+76 §9(Light +4) §8(+123.88)", "§7Speed: §a+4 §9(Light +4) §8(+6.52)", "", "§9Growth V, §9Protection V", "§9Thorns III", "", "§7Increase the damage you deal", "§7with arrows by §c5%§7.", "", "§6Full Set Bonus: Skeleton Soldier", "§7Increase the damage you deal", "§7with arrows by an extra §c25%§7.", "", "§aPerfect 52500 / 52500", "§5§lEPIC DUNGEON LEGGINGS"),
MooConfigPreview.createDungeonItem("clean", "7/11/20 12:27 PM", "§7Gear Score: §d359 §8(561)", "§7Crit Chance: §c+11% §9(Clean +8%)", "§7Crit Damage: §c+26% §8(+42.38%)", "", "§7Health: §a+126 HP §9(Clean +15 HP) §8(+205.38 HP)", "§7Defense: §a+87 §9(Clean +15) §8(+141.81)", "", "§9Growth V, §9Protection V", "§9Thorns III", "", "§7Increase the damage you deal", "§7with arrows by §c5%§7.", "", "§6Full Set Bonus: Skeleton Soldier", "§7Increase the damage you deal", "§7with arrows by an extra §c25%§7.", "", "§aPerfect 52500 / 52500", "§5§lEPIC DUNGEON LEGGINGS")));
+ Property propDungItemHideGearScore = subCat.addConfigEntry(cfg.get(configCat.getConfigName(),
+ "dungItemHideGearScore", false, "Hide Gear Score?"));
+
Property propDungItemToolTipToggleKeyBinding = subCat.addConfigEntry(cfg.get(configCat.getConfigName(),
"dungItemToolTipToggleKeyBinding", Keyboard.KEY_LSHIFT, "Key to toggle dungeon item tooltip"));
@@ -669,6 +673,7 @@ public class MooConfig {
// Category: SkyBlock Dungeons
showItemQualityAndFloor = propShowItemQualityAndFloor.getString();
dungItemQualityPos = propDungItemQualityPos.getString();
+ dungItemHideGearScore = propDungItemHideGearScore.getBoolean();
dungItemToolTipToggleKeyBinding = propDungItemToolTipToggleKeyBinding.getInt();
dungSendPerformanceOnDeath = propDungSendPerformanceOnDeath.getBoolean();
dungOverlayEnabled = propDungOverlayEnabled.getBoolean();
@@ -750,6 +755,7 @@ public class MooConfig {
// Category: SkyBlock Dungeons
propShowItemQualityAndFloor.set(showItemQualityAndFloor);
propDungItemQualityPos.set(dungItemQualityPos);
+ propDungItemHideGearScore.set(dungItemHideGearScore);
propDungItemToolTipToggleKeyBinding.set(dungItemToolTipToggleKeyBinding);
propDungSendPerformanceOnDeath.set(dungSendPerformanceOnDeath);
propDungOverlayEnabled.set(dungOverlayEnabled);
diff --git a/src/main/java/de/cowtipper/cowlection/listener/skyblock/DungeonsListener.java b/src/main/java/de/cowtipper/cowlection/listener/skyblock/DungeonsListener.java
index e2be6c4..1ca65fa 100644
--- a/src/main/java/de/cowtipper/cowlection/listener/skyblock/DungeonsListener.java
+++ b/src/main/java/de/cowtipper/cowlection/listener/skyblock/DungeonsListener.java
@@ -162,11 +162,20 @@ public class DungeonsListener {
}
if (showItemQualityAndFloor) {
if (MooConfig.isDungItemQualityAtTop()) {
- // replace gear score with item quality + obtained floor to top of tooltip
- tooltipIterator.set(customGearScore.toString());
+ if (MooConfig.dungItemHideGearScore) {
+ // replace gear score with item quality + obtained floor to top of tooltip
+ tooltipIterator.set(customGearScore.toString());
+ } else {
+ // add item quality + obtained floor
+ tooltipIterator.add(customGearScore.toString());
+ }
} else {
// add item quality + obtained floor to bottom
itemQualityBottom = customGearScore.toString();
+ if (MooConfig.dungItemHideGearScore) {
+ // remove gear score entry
+ tooltipIterator.remove();
+ }
}
}
continue;