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

Macro for multiple ability checks in a row

Hello everyone,  I am fairly new to using macros and hope that someone can help me. I play in a campaign as a druid and me and my DM have homebrewed that I can turn my Goodberries into healing potions that expire just as fast as the berries itself. The potions are created via a medicine check which is repeated for every spellslot used to summon the berries and turn them into potions. Now, I found it a little annoying having to spam 10 medicine checks before a long rest to turn all my spellslots into potions, and wondered if there is a macro that lets me input the number of times I want to roll a specific ability check (in this case medicine). After some googling I found this: [[?{Roll How many times}d20+6*?{Roll How many times}]] It works well, however, I noticed that it only adds the +6 at the end of all the rolls and not to the individual checks.  Can anyone tell me if there is a macro that lets me roll a determined number of ability checks that have the bonus individually added, not just at the end. Thank you for any help and sorry if this question got too long.
1616166778
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Try this: [[[[?{Roll How many times}d20+6]]*?{Roll How many times}]]
Unfortunately, that does not let me see the individual rolls when hovering over the result, which I need to determine the dc of the potion-making.
If I understand you correctly, you want the 'Roll How many times' to be the number of times you have a 1d20+6 rolled. So if you input a 3, the output you want is [1d20+6]] + [[1d20+6]] + [[1d20+6]]. It's not going to be possible to do that directly without the API. But I believe you might be able to do it with a rollable table or a macro mule character, by creating a separate 'roll' macro or table for each possible 'Roll How many times'. If you only have up to 10, that wouldn't be terrible to set up, but if you have more then that would get pretty cumbersome.
It will be possible with a Chat Menu, but not a query, because attribute and ability calls happen before queries.
If you're interested, here's a quick look at what the output looks like: Oran has a Token Action named DiceRoll. Clicking on that gets the first Medicine Check Menu .  Then clicking on the number 3 gets the Medicine Check Roll  with 3 rolls. I hovered over the 2nd roll, showing that it was a 1d20 roll of 4, plus 6, for a total of 10. The Character Sheet I built for the rolls (named 'Dice') looks like this:
There is one way to roll multiple dice and add a modifier to each roll, via group rolls, but only when directly comparing one roll expression to a dc/target number [[ {?{Roll How many times}d20+6}>?{DC} ]] This would roll the provided number of d20's, add 6 to each, then tell you how many met or exceed the DC you provided. It's a little counter-intuitive since it's an exception to how group rolls typically work and dropping the target number part changes how it handles rolls.
RainbowEncoder said: There is one way to roll multiple dice and add a modifier to each roll, via group rolls, but only when directly comparing one roll expression to a dc/target number [[ {?{Roll How many times}d20+6}>?{DC} ]] This would roll the provided number of d20's, add 6 to each, then tell you how many met or exceed the DC you provided. It's a little counter-intuitive since it's an exception to how group rolls typically work and dropping the target number part changes how it handles rolls. That is really close to what I imagined, thank you! :) The only Problem is, that the potions I'm rolling Medicine for have different DCs, so the weakest Potion I can make is DC10, the next 15 etc. With this is can only roll for 1 of the DCs and have to check manually if any rolls exceeded any of the higher DCs, but thats still way better than spamming the Chat with 10 individual Medicine Checks :D Again, thank you for your help.
Milhouse said: That is really close to what I imagined, thank you! :) The only Problem is, that the potions I'm rolling Medicine for have different DCs, so the weakest Potion I can make is DC10, the next 15 etc. With this is can only roll for 1 of the DCs and have to check manually if any rolls exceeded any of the higher DCs, but thats still way better than spamming the Chat with 10 individual Medicine Checks :D Again, thank you for your help. In that case it's not really that helpful since it still shows the raw rolls in the tooltip. You can fold the +6 modifier onto the dice themselves though. [[ ?{Roll How many times}d(20+6)r<6 ]] That will roll the specified number of dice each returning between 7 (1+6) and 26 (20+6). Any roll too low to have the full modifier added is rerolled and would appeared greyed out. You could even mix the two macros and add some colour highlighting [[ {?{Roll How many times}d(20+6)r<6cs>15}>10} ]] This will give you the count of how many potions you've made in total and use the critical success highlighting to indicate higher quality potions