aboutsummaryrefslogtreecommitdiff
path: root/features/waypoints
diff options
context:
space:
mode:
authorSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2022-07-06 09:15:37 +0800
committerSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2022-07-06 09:15:37 +0800
commit378545ab6d2aab0cc88f6ddfb3252bc942bec1b8 (patch)
treece1362ff1e2db87b33ebe5d8760e83de4004a834 /features/waypoints
parentf629a66ae7c4733657095e0fb40ca6e590565d30 (diff)
downloadSoopyV2-378545ab6d2aab0cc88f6ddfb3252bc942bec1b8.tar.gz
SoopyV2-378545ab6d2aab0cc88f6ddfb3252bc942bec1b8.tar.bz2
SoopyV2-378545ab6d2aab0cc88f6ddfb3252bc942bec1b8.zip
+ crap tone of dungeonRoutes progress
+ added /snoopy and /snoopyv2 commands for pepegas + fix small bug with CH waypoints
Diffstat (limited to 'features/waypoints')
-rw-r--r--features/waypoints/index.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/features/waypoints/index.js b/features/waypoints/index.js
index f9eb039..8d20a64 100644
--- a/features/waypoints/index.js
+++ b/features/waypoints/index.js
@@ -44,6 +44,12 @@ class Waypoints extends Feature {
this.userWaypointsArr = Object.values(this.userWaypoints)
this.updateWaypointsHashes()
this.waypointsChanged = false
+ this.lastTp = 0
+ this.registerEvent("messageSent", (m) => {
+ if (m.toLowerCase().startsWith("/warp")) {
+ this.lastTp = Date.now()
+ }
+ })
this.patcherWaypoints = []
@@ -176,7 +182,7 @@ class Waypoints extends Feature {
minewaypoints_socket.setServer(server, World.getWorld().func_82737_E())
- if (Date.now() - this.lastSend > 1000) {
+ if (Date.now() - this.lastSend > 1000 && Date.now() - this.lastTp > 5000) {
Scoreboard.getLines().forEach(line => {
line = ChatLib.removeFormatting(line.getName()).replace(/[^0-9A-z]/g, "")
if (Object.keys(areas).includes(line)) {