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/CHAT/MACRO to toggle ability token actions on and off.

Is there a way to use setattr or another API or trick to an ability to token action and back off? 
1623788123
The Aaron
Roll20 Production Team
API Scripter
While it's possible to turn the setting on/off, the button doesn't disappear and reappear without deselecting and reselecting the token.
1623788283
The Aaron
Roll20 Production Team
API Scripter
I wrote a script (6 years ago!?!) for toggling abilities off when you used them:&nbsp;&nbsp; <a href="https://app.roll20.net/forum/permalink/1143437/" rel="nofollow">https://app.roll20.net/forum/permalink/1143437/</a> I'm not sure if that would meet your needs, but there it is...
UsePower API looks pretty cool. But if I were to use setattr what would the command look like? !setattr --sel Abilityname|On&nbsp;
1623852625

Edited 1623863791
GiGs
Pro
Sheet Author
API Scripter
setattr can only change attribute values IIRC - whether an ability is enabled or disabled isn't an attribute value.
1623861672
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Correct, abilities are an API object, and would require a script other than ChatSetAttr to affect.