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 .
×

Multiple outputs from a roll

Hello! Sorry if this is retreading previously-covered ground, but I'm looking to make a dice macro for a dice system where: You roll a pool of d6s. You want to know the highest value. Multiple 6s are a crit. Sometimes, 1s and 2s cause bad stuff (glitches). I can do 1 and 2 with @{Attribute} d6k1s, but I'd like it if a roll result of, e.g. (1, 6, 6) could output: [6, Crit, 1 glitch].  Any advice?
1553358695
The Aaron
Roll20 Production Team
API Scripter
You’re pretty much firmly in the realm of API for advanced things like that. The best you can do without it would be to use /r and sort descending, and maybe some coloring: /r @{Attribute} d6sdcs6cs2cf2cf1
Ah well. Thanks for the response, and I'll try that macro out!
1553392900

Edited 1553392938
GiGs
Pro
Sheet Author
API Scripter
Aaron, should that cs2 be there? /r @{Attribute}d6sdcs6cs2cf2cf1 Shouldn't it be /r @{Attribute}d6sdcs6cf2cf1 or even /r @{Attribute}d6sdcs6cf<2
1553401439
Kraynic
Pro
Sheet Author
I think it depends on whether a 2 result is different than a 1 result.  In The Aaron's example, the 1 would be outlined in red and 2 in blue.  If there is no difference at all between 1 and 2, then yours would be cleaner.
1553404747
GiGs
Pro
Sheet Author
API Scripter
Actually it looks like when there are both cs2 and cf2, it just shows red. I just tested this, and it doesnt matter the order: if cs and cf exist for the same roll, it's always red. The blue only happens when you get a crit on one die, and fumble on a different die, not if they happen on the same die.
1553408329
Kraynic
Pro
Sheet Author
For some reason, I thought I had done that before for something.  It must have been something with 2 dice then.  That'll teach me to type without checking first!
1553408513
GiGs
Pro
Sheet Author
API Scripter
I thought it would work that way too, before I tested it :)
1553442672
The Aaron
Roll20 Production Team
API Scripter
I was thinking then the 2 would be blue, but that might just work on inline rolls. My intent was to make each of 6, 2, and 1 uniquely colored. 
1553450332
Kraynic
Pro
Sheet Author
Yeah, it works as an inline roll.  I just tested [[1d6sdcs6cs2cf2cf1]], and the 2 displays as blue.
1553454726
GiGs
Pro
Sheet Author
API Scripter
That's weird. It works as an inline roll but not in this format /roll 1d6sdcs6cs2cf2cf1
1553490658
The Aaron
Roll20 Production Team
API Scripter
I guess technically, it only works on the border of an inline roll, not the individual dice.