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

Macro for success with percentile crits

Hi. I am working with a roll-under percentile system and I was wondering if there's any way to automate the roll so it accounts for crits as well as success/failures. Essentially, so that it checks two target numbers. Example: Skill X is at 55% with a crit of 9%. Right now I have it so it just checks for the success of the roll (55 or lower) but not the crit (9 or lower) -- we manually check the roll with the character sheet -- with "/r d100<55" There's probably some way to automate comparing the rolled result to the second target number, but how to do it is beyond me.
You'd probably have to make two separate rolls. You can't carry the value from one roll into another. /me makes [[ 1d100<55 ]] successful attempts and [[ 1d100<9 ]] CRITICAL attempts! Output(rolling a 47and a 42): Mark G. (GM) (GM) makes 1 successful attempts and 0 CRITICAL attempts! Output(rolling a 12 and a 9): Mark G. (GM) (GM) makes 1 successful attempts and 1 CRITICAL attempts! (There may be better ways, and always a good chance Gauss will reply with some brain-torturing magic-macro)
1390616664
Gauss
Forum Champion
Nope, no magic macro. Taking a single die roll and putting it through two checks is firmly in the API territory (a Mentor level feature). If your GM is a Mentor then I suggest asking the API forum for a script to re-use the roll for a later check.
how about this? /r {[[success number]], [[crit number]]}>[[roll+modifiers]] if it gives you 0 successes you fail, 1 you hit, 2 you crit. you need the in-lines to make it work if i remember correctly from when i was going to use a system like this for all my characters attack macros, but it doesnt scale to multiple attacks the way i wanted it to so i switched to weapon attack vs [[target|armor class]] , [[crit threat number+attack mods]] crits [[attack roll]] [[secondary attack roll]] etc.... [[damage roll]] [[secondary damage roll]] etc....
1390665355

Edited 1390665498
Teldurn
KS Backer
I am the GM for our game and unfortunately I don't have wiggle room in the budget this year to get Mentor. I guess we will stick with the current method of checking manually. Thanks for the replies, everyone. Cheers. edit: Roger, that is basically what I was going for. I will give it a try and see if it works.
1390706200
GiGs
Pro
Sheet Author
API Scripter
Mark G. said: You'd probably have to make two separate rolls. You can't carry the value from one roll into another. /me makes [[ 1d100<55 ]] successful attempts and [[ 1d100<9 ]] CRITICAL attempts! Output(rolling a 47and a 42): Mark G. (GM) (GM) makes 1 successful attempts and 0 CRITICAL attempts! Output(rolling a 12 and a 9): Mark G. (GM) (GM) makes 1 successful attempts and 1 CRITICAL attempts! (There may be better ways, and always a good chance Gauss will reply with some brain-torturing magic-macro) To get the corrrect odds, the chance of a crit should always be 20%. This works: /roll (1d100<@{Score})*[[(1d5>5+1)]] or /roll (1d100<?{Score})*[[(1d5>5+1)]] The first bracketed section is the percential roll against your skill. The second part takes into account that 1/5th of successes are criticals. This macro will give 3 results: "0 Successes" (fail), "1 success" (success), and "2 successes" (critical).
Thanks GG. But unfortunately that won't work because crit ranges in this game fluctuate between 1% to 20% and sometimes much higher, like up to 75% in very rare cases.
Alex H. said: Thanks GG. But unfortunately that won't work because crit ranges in this game fluctuate between 1% to 20% and sometimes much higher, like up to 75% in very rare cases. You could insert a variable for the fluctuating crit chance, but in practice it may prove annoying since you need to manually add it for every roll (even the ones that miss).
1391118681
GiGs
Pro
Sheet Author
API Scripter
As GM Mu points out, you can change this part "*[[(1d5>5+1)]]" to a variable call, like "*[[@{Critical}/100]]. /roll (1d100<@{Score})*[[@{Critical}/100]] If the crit is fixed for each skill, you'll need a separate ability for each crit chance. If the crit varies on a per roll basis, you can use a prompt like this: /roll (1d100<@{Score})*[[?{Critical}]] Tthat will prompt you on each roll for the critical chance.
For the sake of posterity, and perhaps helping someone else with this problem, here's the solution that worked best for me and this game (without a Mentor subscription). Taking the Firearms skill as an example: /r (d100<@{Firearms})[[@{Crit Chance}]] Crit Chances only potentially fluctuate at level ups, so it's not a worry during play. A visual check is needed to see if crits happen, but since it outputs the crit chance right there, no need to check character sheet each time.