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

Api teleport help

i am a new to the api and really wanted to use this script <a href="https://app.roll20.net/forum/post/193270/script-auto-teleporting-and-chat-based-teleporting#post-233925" rel="nofollow">https://app.roll20.net/forum/post/193270/script-auto-teleporting-and-chat-based-teleporting#post-233925</a> without the movement tracker but every time i try to use the two way teleport the tokens i use just stack on each other and then when i try to teleport a token it gives me this error ReferenceError: obj is not defined at Object.Teleporter.Teleport (evalmachine.&lt;anonymous&gt;:581:19) at Sandbox.&lt;anonymous&gt; (evalmachine.&lt;anonymous&gt;:634:24) at eval ( any help would be nice
1417632944
The Aaron
Roll20 Production Team
API Scripter
So, you have modified the script? Can you post your modified version in a code block here?
i dont think i did, i just copy and pasted the one in that thread that was labled "teleporter without movement tracker"
1417633558

Edited 1417720823
The Aaron
Roll20 Production Team
API Scripter
This is a pretty old script. It's probably failing on this line: Teleporter.Teleport = function (CharName, TargetName) { var LocX = 0; var LocY = 0; var OldLocX = obj.get("left"); It's one of those cases of "I dont see how this could have ever worked." obj is not defined in the function, so would inherit whatever definition it had in the global scope. Likely it gets set in some other script the author was using, and happened to be the right one. It's a bit sloppy and unfortunate. There is a newer teleport script from last week or so that should be better. You might see if it meets your needs.
alright, thank you very much. very new to this so its kinda confusing but really intresting
1417636408
The Aaron
Roll20 Production Team
API Scripter
No worries. BTW, the API forum is probably a better place for discussing the API. I'm guessing you found this script on the stickied post that lists scripts. That post is probably about as out dated as this script. =D You're better off reading through the forum, or posting a request for what you're after. We try to fill the needs people present, but only if they present them! =D