aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/io
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/io')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SkillOverlays.java52
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/CombatSkillOverlay.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingSkillOverlay.java (renamed from src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java)8
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/FishingSkillOverlay.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/MiningSkillOverlay.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/OverlayManager.java4
6 files changed, 61 insertions, 9 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SkillOverlays.java b/src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SkillOverlays.java
index 943417e6..ca970a84 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SkillOverlays.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SkillOverlays.java
@@ -100,6 +100,19 @@ public class SkillOverlays {
@Expose
@ConfigOption(
+ name = "Pause Timer",
+ desc = "How many seconds does it wait before pausing"
+ )
+ @ConfigAccordionId(id = 0)
+ @ConfigEditorSlider(
+ minValue = 1,
+ maxValue = 20,
+ minStep = 1
+ )
+ public int farmingPauseTimer = 3;
+
+ @Expose
+ @ConfigOption(
name = "Edit Farming Overlay Position",
desc = "Change the position of the Farming overlay"
)
@@ -159,6 +172,19 @@ public class SkillOverlays {
@Expose
@ConfigOption(
+ name = "Pause Timer",
+ desc = "How many seconds does it wait before pausing"
+ )
+ @ConfigAccordionId(id = 1)
+ @ConfigEditorSlider(
+ minValue = 1,
+ maxValue = 20,
+ minStep = 1
+ )
+ public int miningPauseTimer = 3;
+
+ @Expose
+ @ConfigOption(
name = "Edit Mining Overlay Position",
desc = "Change the position of the Mining overlay"
)
@@ -220,6 +246,19 @@ public class SkillOverlays {
@Expose
@ConfigOption(
+ name = "Pause Timer",
+ desc = "How many seconds does it wait before pausing"
+ )
+ @ConfigAccordionId(id = 3)
+ @ConfigEditorSlider(
+ minValue = 1,
+ maxValue = 20,
+ minStep = 1
+ )
+ public int fishingPauseTimer = 3;
+
+ @Expose
+ @ConfigOption(
name = "Edit Fishing Overlay Position",
desc = "Change the position of the Fishing overlay"
)
@@ -314,6 +353,19 @@ public class SkillOverlays {
@Expose
@ConfigOption(
+ name = "Pause Timer",
+ desc = "How many seconds does it wait before pausing"
+ )
+ @ConfigAccordionId(id = 4)
+ @ConfigEditorSlider(
+ minValue = 1,
+ maxValue = 20,
+ minStep = 1
+ )
+ public int combatPauseTimer = 3;
+
+ @Expose
+ @ConfigOption(
name = "Edit Combat Overlay Position",
desc = "Change the position of the Combat overlay"
)
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/overlays/CombatSkillOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/overlays/CombatSkillOverlay.java
index d73b5eb2..45ce0098 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/overlays/CombatSkillOverlay.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/overlays/CombatSkillOverlay.java
@@ -179,7 +179,7 @@ public class CombatSkillOverlay
float delta = totalXp - lastTotalXp;
if (delta > 0 && delta < 1000) {
- xpGainTimer = 3;
+ xpGainTimer = NotEnoughUpdates.INSTANCE.config.skillOverlays.combatPauseTimer;
xpGainQueue.add(0, delta);
while (xpGainQueue.size() > 30) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingSkillOverlay.java
index 970c74ab..39b64136 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingSkillOverlay.java
@@ -37,7 +37,7 @@ import java.util.LinkedList;
import java.util.List;
import java.util.function.Supplier;
-public class FarmingOverlay extends TextOverlay {
+public class FarmingSkillOverlay extends TextOverlay {
private long lastUpdate = -1;
private int counterLast = -1;
private int counter = -1;
@@ -66,7 +66,7 @@ public class FarmingOverlay extends TextOverlay {
private String skillType = "Farming";
- public FarmingOverlay(
+ public FarmingSkillOverlay(
Position position,
Supplier<List<String>> dummyStrings,
Supplier<TextOverlayStyle> styleSupplier
@@ -284,7 +284,6 @@ public class FarmingOverlay extends TextOverlay {
}
}
}
-
skillInfoLast = skillInfo;
skillInfo = XPInformation.getInstance().getSkillInfo(skillType);
if (skillInfo != null) {
@@ -294,7 +293,8 @@ public class FarmingOverlay extends TextOverlay {
float delta = totalXp - lastTotalXp;
if (delta > 0 && delta < 1000) {
- xpGainTimer = 3;
+
+ xpGainTimer = NotEnoughUpdates.INSTANCE.config.skillOverlays.farmingPauseTimer;
xpGainQueue.add(0, delta);
while (xpGainQueue.size() > 30) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/overlays/FishingSkillOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/overlays/FishingSkillOverlay.java
index 717ff944..b1143042 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/overlays/FishingSkillOverlay.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/overlays/FishingSkillOverlay.java
@@ -180,7 +180,7 @@ public class FishingSkillOverlay
float delta = totalXp - lastTotalXp;
if (delta > 0 && delta < 1000) {
- xpGainTimer = 3;
+ xpGainTimer = NotEnoughUpdates.INSTANCE.config.skillOverlays.fishingPauseTimer;
xpGainQueue.add(0, delta);
while (xpGainQueue.size() > 30) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/overlays/MiningSkillOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/overlays/MiningSkillOverlay.java
index a20b1d27..4422e3ad 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/overlays/MiningSkillOverlay.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/overlays/MiningSkillOverlay.java
@@ -172,7 +172,7 @@ public class MiningSkillOverlay
float delta = totalXp - lastTotalXp;
if (delta > 0 && delta < 1000) {
- xpGainTimer = 3;
+ xpGainTimer = NotEnoughUpdates.INSTANCE.config.skillOverlays.miningPauseTimer;
xpGainQueue.add(0, delta);
while (xpGainQueue.size() > 30) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/overlays/OverlayManager.java b/src/main/java/io/github/moulberry/notenoughupdates/overlays/OverlayManager.java
index fef11a45..d580b556 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/overlays/OverlayManager.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/overlays/OverlayManager.java
@@ -30,7 +30,7 @@ public class OverlayManager {
public static Class<? extends TextOverlay> dontRenderOverlay = null;
public static MiningOverlay miningOverlay;
- public static FarmingOverlay farmingOverlay;
+ public static FarmingSkillOverlay farmingOverlay;
public static FishingSkillOverlay fishingSkillOverlay;
public static MiningSkillOverlay miningSkillOverlay;
public static CombatSkillOverlay combatSkillOverlay;
@@ -106,7 +106,7 @@ public class OverlayManager {
"\u00a7bXP/h: \u00a7e238,129",
"\u00a7bYaw: \u00a7e68.25\u00a7l\u1D52"
);
- farmingOverlay = new FarmingOverlay(NotEnoughUpdates.INSTANCE.config.skillOverlays.farmingPosition, () -> {
+ farmingOverlay = new FarmingSkillOverlay(NotEnoughUpdates.INSTANCE.config.skillOverlays.farmingPosition, () -> {
List<String> strings = new ArrayList<>();
for (int i : NotEnoughUpdates.INSTANCE.config.skillOverlays.farmingText) {
if (i >= 0 && i < farmingDummy.size()) strings.add(farmingDummy.get(i));