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

Help with chat attribution script

I'm looking for help with the ChatSetAttr that shows up in the API library. I'm trying to figure out if there's a way to modify an attribute by a dice roll rather than a fixed number / calculation. Thanks
1493154238

Edited 1493154263
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Jakob may come by and tell me I'm wrong, but looking at the code, it sure looks like you can. Is it not working for you? What command are you sending?
!setattr --sel --mod --Strength| [rollcommand]
1493154969
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
What are you putting for the roll command?
1493155268
Lithl
Pro
Sheet Author
API Scripter
At a glance, the script is handling inline rolls, so you would want something like !setattr --sel --mod --Strength|[[d8]] instead of !setattr --sel --mod --Strength|d8 .
Lol that was it. Sorry about that (very new to Roll20 and still making lots of mistakes) Thank you for the help!
1493155614
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
np, the macro syntax can be a bit arcane. And then each script has its own eccentricities.