I can't seem to get this TokenMod command to work The Aaron's OnMyTurn script. !token-mod --ids @{Bruce Grayson|character_id} --current-page --set statusmarkers|+half-haze The code itself runs fine when isolated and applies the status marker to the token as wanted, but when I use it in an OnMyTurn ability on Bruce Grayson's character sheet, I get the following error report: For reference, the error message generated was: TypeError: Cannot read properties of undefined (reading 'get')
TypeError: Cannot read properties of undefined (reading 'get')
at apiscript.js:39022:44
at eval (eval at <anonymous> (/home/node/d20-api-server/api.js:168:1), <anonymous>:65:16)
at Object.publish (eval at <anonymous> (/home/node/d20-api-server/api.js:168:1), <anonymous>:70:8)
at /home/node/d20-api-server/api.js:1762:12
at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560
at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147)
at Kd (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:546)
at Id.Mb (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:489)
at Ld.Mb (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:94:425)
at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:111:461 I have tried using the Meta Script Toolbox's Select Manager to inject/select the appropriate token instead, but it kicks back a similar error. I have even tried swapping the Token Mod command out with a Combat Master status-adding command, but the same result happens. The character has a Cloak of Displacement, and that effect returns at the beginning of their turn, so I want it to apply the status whenever his turn comes around. Ideally, I would also like to use the Meta Scripts to only apply it if the token does not have two other certain status markers, but that's another can of worms for after this problem is solved. Thanks in advance for any help you can provide!