diff options
Diffstat (limited to 'features/mining/index.js')
-rw-r--r-- | features/mining/index.js | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/features/mining/index.js b/features/mining/index.js index 644a100..f8f7843 100644 --- a/features/mining/index.js +++ b/features/mining/index.js @@ -69,6 +69,7 @@ class Mining extends Feature { this.metalDetectorSolver = new ToggleSetting("Metal detector solver", "", true, "metal_detector_solver", this) + this.alertTools = new ToggleSetting("Alert when all 4 tools in inventory", "", true, "alert_tools", this) this.seenBalDamages = [] this.balHP = 250 @@ -187,6 +188,28 @@ class Mining extends Feature { let ignoreLocation = undefined let registerActionBar = this.registerCustom("actionbar", (dist) => { + + let lapis = false + let diamond = false + let emerald = false + let gold = false + Player.getInventory().getItems().forEach(i => { + if (i && i.getName().includes("Scavenged Lapis")) { + lapis = true + } + if (i && i.getName().includes("Scavenged Diamond")) { + diamond = true + } + if (i && i.getName().includes("Scavenged Emerald")) { + emerald = true + } + if (i && i.getName().includes("Scavenged Golden")) { + gold = true + } + }) + + if (this.alertTools.getValue() && lapis && diamond && gold && emerald) Client.showTitle("§cALL TOOLS", "", 10, 40, 20) + if (!this.metalDetectorSolver.getValue()) return let distance = parseFloat(dist) if (!this.baseCoordinates) this.findBaseCoordinates(); @@ -196,8 +219,6 @@ class Mining extends Feature { return } - let lastLocation = this.predictedChestLocations[0] - this.predictedChestLocations = [] this.chestCoords.forEach((coordinates) => { |