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

How to conditionally drop highest rolls in a macro?

A game I'm playing has you roll a number of d10s and keep the highest. Not a hard macro, but the game also has results of 1s cancel out your highest, making you take the next highest. Eg. you roll 3d10 and you get 2, 1, and 9 as your result. The 1 cancels out the 9 so you take 2 as your next highest. Is there any way to make that into a macro?
It cannot be done directly but by rolling to check for 1's first then rolling the non-1's afterwards it is possible. This macro will do that but only works as a /roll or /gmroll command /roll { (?{How Many d10's?|1}-[[ [[?{How Many d10's?}d10=1cs0 + 1]]-1]])d10r1sdcf0 + $[[1]]d1cs0 }k$[[0]]dh$[[1]] Whilst rolling the non-1's it may show 1's that get rerolled but only the 1's highlighted in red are 'true' 1's.
that's perfect thank you so much