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

Need help with a teleporting API Script

1532245280

Edited 1532245500
Bird
Pro
So previously I was given this script: <a href="https://gist.github.com/OneLuckyBird/803d3ac32c1c9c84c333dcb471aef931" rel="nofollow">https://gist.github.com/OneLuckyBird/803d3ac32c1c9c84c333dcb471aef931</a> Which works basically as a teleportation.&nbsp; A token on a GM layer named Teleport01A would link with another token named Teleport01B and when a player stepped on it, it would teleport them to the other and vice versa. I've run into some problems though and i'm trying to understand what i'm doing wrong.&nbsp; I've 3 pairs of teleporters named Teleport01A, Teleport02A, so on and so forth, and then the Teleport 01B, Teleport02B, etcetera, basically linking where I want the players to go back and forth.&nbsp; Only Teleporters 02A and 02B link up and allow the player to move freely.&nbsp; Teleporter 03A will teleport the player to 03B but not back.&nbsp; And Teleporter 01A and B don't work at all. Is there something i'm missing?&nbsp; Am I naming them incorrectly?&nbsp; Does anyone have an easier API Script for teleporting?
1532246322
MSG
Pro
Sheet Author
If I read the script right, the 01, 02, 03, etc actually represents the number of "pads" (doors) in that system.&nbsp; For example, Teleport02A and Teleport02B work because there are only 2 pads in that group.&nbsp; Teleport03(letter) is expecting a 3 pad system: Teleport03A, Teleport03B and Teleport03C.&nbsp; Teleport01 is a one-way (1 pad), so it probably doesn't see a 01B. I'm not an API scripter, so you may want to wait until one of them replies to see if they can confirm (or not) my statement,
Interesting.&nbsp; While that's a good point, how would I make multiple, but seperate pads?&nbsp; For example, would I do 'Teleport12A' and 'Teleport12B' for one pair, then 'Teleport22A' and 'Teleport22B' for another?
1532271954
The Aaron
Pro
API Scripter
There's an updated version of that script (several, actually) here:&nbsp; <a href="https://app.roll20.net/forum/permalink/6265365/" rel="nofollow">https://app.roll20.net/forum/permalink/6265365/</a> And here are instructions on naming things from that thread, which should apply even to the old version:&nbsp;<a href="https://app.roll20.net/forum/permalink/6573220/" rel="nofollow">https://app.roll20.net/forum/permalink/6573220/</a>
The Aaron said: There's an updated version of that script (several, actually) here:&nbsp; <a href="https://app.roll20.net/forum/permalink/6265365/" rel="nofollow">https://app.roll20.net/forum/permalink/6265365/</a> And here are instructions on naming things from that thread, which should apply even to the old version:&nbsp; <a href="https://app.roll20.net/forum/permalink/6573220/" rel="nofollow">https://app.roll20.net/forum/permalink/6573220/</a> Wonderful.&nbsp; Trivia fact:&nbsp; You're the one who gave me the script back in the day. Good to see you still around!
1532292643
The Aaron
Pro
API Scripter
=D&nbsp; Where would I go where they'd have me!?&nbsp;&nbsp; Glad you got it working. =D
The Aaron said: =D&nbsp; Where would I go where they'd have me!?&nbsp;&nbsp; Glad you got it working. =D Yup.&nbsp; Fully tested and it works wonderfully.&nbsp; Thanks again.