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

Natural 20 and natural 1 roll macro

I am looking to add some excitement to natural 20 and natural 1 rolls. Obviously with a ability check roll of natural 20 equals best possible outcome and a natural 1 roll equals worst possible outcome. I know the chat box will show a 20 roll as a green box and a 1 roll as a red box but I am looking to add something to the bottom of the macro to really distinguish a nat 1 or nat 20. As far as I can tell if/else statements don't exist because the macros aren't a true programming language but I feel like there has to be something. Take the below example macro of a basic attack for a toon named Tom. He rolls 1d20 adds whatever modifiers and the result is shown below. This is simple enough Tom's Attack Macro /roll 1d20+modifiers show roll result Now if I could add something to the bottom of the macro like the example if statement I would be set. If 1d20 roll = 20 then print "Tom succeeds in his attempt", if 1d20 roll = 1 then print "Tom fails in his attempt", if anything else end macro and display nothing beyond the roll results
1585925359
Kraynic
Pro
Sheet Author
If/then statements don't exist for the dice roller, so that would be the domain of api scripts (pro account). However, you could (instead of a simple statement) create a rollable table of critical failure statements, a rollable table of critical success statements, and then incorporate chat menu button entries for each table under the rolls in which you want them.&nbsp; I guess you could have it just print a simple statement instead of doing a table, but tables are fun, right? Chat menus are one of the entries in the Stupid Tricks pinned thread at the top of this forum.&nbsp; <a href="https://app.roll20.net/forum/permalink/5927072/" rel="nofollow">https://app.roll20.net/forum/permalink/5927072/</a>