Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Error using Ping Buddy

1723409864

Edited 1723410895
Hi, I'm getting the following error when enabling Ping Buddy in my game: TypeError: Cannot read properties of undefined (reading 'restoreColor') TypeError: Cannot read properties of undefined (reading 'restoreColor') at apiscript.js:15257:106 at eval (eval at <anonymous> (/home/node/d20-api-server/api.js:169:1), <anonymous>:65:16) at Object.publish (eval at <anonymous> (/home/node/d20-api-server/api.js:169:1), <anonymous>:70:8) at /home/node/d20-api-server/api.js:1564:14 at process.processTicksAndRejections (node:internal/process/task_queues:95:5) Any idea what could be causing it?
1723410877

Edited 1723412163
For context: I made a copy of a previous game and added all the same scripts to it. Ping Buddy still works in my old games, but I'm not sure what I could have changed in the new one to cause the error. As far as I can recall, I have only used the transmogrifier to transfer a character or two. Edit: Recreated the error by copying an old game and adding the script without making any changes at all to the game itself.
1723412253
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hi Axiomsyndrom! Just checking: is the new game in Jumpgate? As a just-in-case measure, try setting the GM color manually to something else. (click on the color swatch next to your name in the player avatar area). For reference, to use an invisible ping (such as when the idea is only to follow a token as it moves, without the animation), the script temporarily changes the GM color to transparent, stores the old value and restores it after the ping resolves. Due to Roll20 timing, such as in the case of a rapid succession of calls (ex. moving a party token), it can get confused.
Hi Keith, Updating the GM color seems to have resolved the confusion. Thank you! i was not using Jumpgate, just regular old Roll20 :)
1723412441
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Also a caveat: There is a new ping system eventually slated for Jumpgate. The script will probably need to be re-written after that, as I anticipate a significant library of new features.
Im getting this error when trying to pingmesilent tokens name, No token named with that name can be found on this page. Make sure that the player flag is on this page as well. but if I use pingme token name then it works but pulls everyone on the map. Would love a bit of help here if possible.
1726527510
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hi David! Can you give me the token's name for testing purposes?
1726528475

Edited 1734571277
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Never Mind, I found the issue. I thought I had a pretty simple fix, but it exposed a few other issues. This will need some attention, and the whole script will need an uplift for Jumpgate eventually. I will try to debug this and post a Pull Request this week. EDIT: sendPing on Jumpgate is now fixed.
Thank you