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

'Bounce Token' script, how to select a token?

I downloaded and installed the "Bounce Token" script but you have to select the token before running !bounce-start and it takes no variables so I can't specify a name or ID. Is there a macro command to select a token based on name or id?
1523201844
The Aaron
Pro
API Scripter
Nope, but I can add ids as parameters to the bounce commands if that works better for you.
The Aaron said: Nope, but I can add ids as parameters to the bounce commands if that works better for you. Could you? That would be amazing. I would really appreciate it. I'm a programmer and have been programming for 20 years and have 12 years work experience but I've only been using roll20 for less than 2 weeks and I know next to nothing about the API and how to get values from certain objects. Again, thank you. I would really appreciate your help.
1523203217
The Aaron
Pro
API Scripter
Done, Grab the latest version here:&nbsp; <a href="https://github.com/shdwjk/Roll20API/blob/master/Bo" rel="nofollow">https://github.com/shdwjk/Roll20API/blob/master/Bo</a>... Just add the tokens to the commands after a -- like this: !bounce-start -- -L9XHELqgSj0r_77UiKK -L96YMfTqFCcrKa88bkZ
1523203335

Edited 1523203397
MyRoll20Stuffs
API Scripter
Thanks man! Can you still specify a second interval for the bounce when using ids? Like: !bounce-start 3 -- -L9XHELqgSj0r_77UiKK -L96YMfTqFCcrKa88bkZ Edit: And can you &nbsp;!bounce-stop -- -L9XHELqgSj0r_77UiKK -L96YMfTqFCcrKa88bkZ As well?
1523203464
The Aaron
Pro
API Scripter
Yup, that's the reason for the --, to make it easy to determine what are IDs and what are parameters.&nbsp; You can see it in the help with: !bounce-start --help
1523203811

Edited 1523203830
MyRoll20Stuffs
API Scripter
Thanks so much for this! You're a life saver! I have an encounter where the party is on a boat going down the river. I made a macro to move lizardfolk from gmlayer to object layer and play a splash sfx, now I can make them bob up and down in the water! Thanks again!
1523204544

Edited 1523204995
MyRoll20Stuffs
API Scripter
The !bounce-start 3 -- [ID] is working perfectly But when I run !bounce-stop -- [ID] I get API errors: Nevermind. Must have been something on my end. It works perfectly now. EDIT: 2 Nope it still gives errors half the time.
1523204971
The Aaron
Pro
API Scripter
Ah, there's an assumption in the code that the id provided is actually bouncing. =D&nbsp; I'll fix that real quick.
The Aaron said: Ah, there's an assumption in the code that the id provided is actually bouncing. =D&nbsp; I'll fix that real quick. Ahhh okay. Thanks!
1523205086
The Aaron
Pro
API Scripter
Updated:&nbsp; <a href="https://github.com/shdwjk/Roll20API/blob/master/Bo" rel="nofollow">https://github.com/shdwjk/Roll20API/blob/master/Bo</a>...
The Aaron said: Updated:&nbsp; <a href="https://github.com/shdwjk/Roll20API/blob/master/Bo" rel="nofollow">https://github.com/shdwjk/Roll20API/blob/master/Bo</a>... Works perfectly now! I can spam my macro buttons back and forth and no errors and they go from bouncing to not bouncing with no issues! Thank you for this Mr Arcane Scriptomancer!
1523205345
The Aaron
Pro
API Scripter
No problem! =D