Closed shemetz closed 2 years ago
I believe a solution might be to change the case to case canvas.tokens.name
.
For now, as a workaround, I can type the following in the console to temporarily fix the issue:
Object.defineProperty(canvas.tokens, "name", {
get: function() { return 'TokenLayer' }
});
@itamarcu Thank you for the report!
It'd be better to just not check for exact constructor names
(PF2e v3.3.0, TokenMagic FX v0.5.3)
None of the macros work for me, because they all rely on the
getControlledPlaceables
function which has the following line:When debugging, I see that:
canvas.activeLayer.name
='TokenLayerPF2e'
TokenLayer.name
='TokenLayer'
and for that reason, the code enters none of the cases, ending up with a list of 0 controlled placeables, causing nothing to happen.