Closed JohnSBarden closed 4 years ago
Sorry, this is an issue with Difficult Terrain/Terrain Layer, not Show Drag Distance.
What is terrain-calculation.js? I see that in the callstack. I'm making some fixes to Terrain Layer and ShowDragDistance so they work together, but they shouldn't be live yet.
It was due to not having Terrain Layer installed/enabled, and it was attempting to calculate based on the Difficult Terrain without any placed/not having its dependency.
Module works fine on initial load, but as soon as I switch scenes, it stops calculating correctly. Worked on a previous version.
Gif of issue
Console shows the following error
Uncaught TypeError: Cannot read property 'costGrid' of undefined at Function.checkForTerrain (terrain-calculation.js:94) at player-data.js:82 at Array.map ()
at Boolean.handleMouseMove (player-data.js:82)
at e.a.emit (index.js:181)
at r.dispatchEvent (InteractionManager.js:1028)
at r.processPointerMove (InteractionManager.js:1499)
at pr.recursiveFindHit (TreeSearch.js:166)
at pr.findHit (TreeSearch.js:191)
at r.processInteractive (InteractionManager.js:1097)
Replicated in Firefox and Chrome.
Using FoundryVTT v0.6.6 system: PF2e v1.10.13.2079 Show Drag Distance v2.1.9