Use canvas.scene.grid.type instead of cnavas.scene.gridType (which is undefined since v10) (fixes #272)

This commit is contained in:
Manuel Vögele
2023-06-12 22:20:30 +02:00
parent 8101381cc4
commit 48d0d17628
+1 -1
View File
@@ -185,7 +185,7 @@ export function highlightMeasurementNative(
tokenShape = [{x: 0, y: 0}], tokenShape = [{x: 0, y: 0}],
alpha = 1, alpha = 1,
) { ) {
const spacer = canvas.scene.gridType === CONST.GRID_TYPES.SQUARE ? 1.41 : 1; const spacer = canvas.scene.grid.type === CONST.GRID_TYPES.SQUARE ? 1.41 : 1;
const nMax = Math.max( const nMax = Math.max(
Math.floor(ray.distance / (spacer * Math.min(canvas.grid.w, canvas.grid.h))), Math.floor(ray.distance / (spacer * Math.min(canvas.grid.w, canvas.grid.h))),
1, 1,