From 1da702b92a1bb9a6b16d5135e9f0e40d4e2d27c8 Mon Sep 17 00:00:00 2001 From: Soopyboo32 <49228220+Soopyboo32@users.noreply.github.com> Date: Mon, 28 Mar 2022 07:47:41 +0800 Subject: Fix stuttering when loading waypoint path --- features/events/index.js | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'features') diff --git a/features/events/index.js b/features/events/index.js index af8a664..c10e2f8 100644 --- a/features/events/index.js +++ b/features/events/index.js @@ -175,7 +175,9 @@ class Events extends Feature { step_5s(){ if(this.showingWaypoints){ if(this.burrialWaypointsPath.getValue() || this.burrialWaypointsNearest.getValue()){ - this.updateBurrialPath() + new Thread(()=>{ + this.updateBurrialPath() + }).start() } } this.sortBurrialLocations() @@ -379,7 +381,9 @@ class Events extends Feature { "chain": -1, "fromApi": false }) - this.updateBurrialPath() + new Thread(()=>{ + this.updateBurrialPath() + }).start() } } } @@ -411,7 +415,9 @@ class Events extends Feature { }) if(this.burrialData.historicalLocations.length > 10) this.burrialData.historicalLocations.pop() if(this.lastPathCords) this.lastPathCords.shift() - this.updateBurrialPath() + new Thread(()=>{ + this.updateBurrialPath() + }).start() } updateBurrialPath(){ if(this.burrialWaypointsPath.getValue() || this.burrialWaypointsNearest.getValue()){ -- cgit