manuelVo / foundryvtt-drag-ruler

A Foundry VTT module that shows a ruler when dragging tokens so you can see how far you've dragged them
MIT License
40 stars 52 forks source link

Error: Selecting or moving a token causes an error when trying to start background caching (develop branch only) #196

Closed schultzcole closed 2 years ago

schultzcole commented 2 years ago

This issue does not affect the version of drag ruler that has been deployed (1.12.8), only what is on the develop branch.

When controlling or moving a token, the function startBackgroundCaching throws an error because the cache layer doesn't contain an entry for the token's position. This doesn't seem to cause any problems in the outwardly visible behavior, but it does show the error in the console and presumably the benefits of the background caching aren't being used because of this error.

Foundry_Virtual_Tabletop_4gVMx1hS6N

It seems that this stems from commit 2979e86201f411003d6b09fa6fa489fab3727bf1 by @JDCalvert which is present on develop, but not master.

manuelVo commented 2 years ago

It appears that this happens only in gridless scenes. Can you confirm that observation?

schultzcole commented 2 years ago

Correct, only on gridless scenes.