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

Teleport API breaks across pages

I have been testing the one-click Teleport API and it works great for cross-page, but I cannot make it work from one page to another. It crashes the API with the following error message: For reference, the error message generated was:  TypeError: Cannot read property 'get' of undefined TypeError: Cannot read property 'get' of undefined at apiscript.js:10811:42 at Array.forEach (<anonymous>) at reconcileTargetPageId (apiscript.js:10810:25) at limboSwap (apiscript.js:10794:17) at teleportToken (apiscript.js:10835:23) at apiscript.js:10646:25 at Function.each (/home/node/d20-api-server/node_modules/underscore/underscore-node-f.cjs:1323:7) at teleportPadCheck (apiscript.js:10618:15) at autoTeleportCheck (apiscript.js:11220:21) at eval (eval at <anonymous> (/home/node/d20-api-server/api.js:154:1), <anonymous>:65:16) Any idea what I'm doing wrong?  Is it maybe an interference with another script? I also have MapChange enabled, but nothing else that looks likely to conflict.
1620904882
David M.
Pro
API Scripter
I don't use it, but you might want to try posting on the  teleport thread  to make sure that Pat gets a forum notification.
I think i read that you need to have a copy of the character on the page you are teleporting to, not sure if that is of any help.
Thanks for the link to the teleport thread.  I do have the character on the destination page, both GM and object layer.  No luck.
1621004116
Andreas J.
Forum Champion
Sheet Author
Translator
You could try disabling MapChange, just in case. Think there was a mention on the Main Teleport thread that there might still be issues with cross-page teleportation.
It turns out the problem was tokens that are controlled by "all players." As soon as I removed "all" from the control list, everything worked beautifully.