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

Roll20 roller cannot handle subtracting negatives?

Hey guys! I've been having trouble regarding a complicated macro that necessitates the use of subtracting negatives. (A bonus subtracts from the dice roll, which is good because the lower the roll the better). However, it seems that roll20 roller can't handle subtracting negatives??? (it can handle adding negatives just fine). For example, rolling: /r 5+-10 gives me the result "-5", which is correct (adding negatives). However, rolling: /r 5--10 gives me the result "0", which is incorrect (should be 5; subtracting negatives). This problem is reflected in the bracketed calculations as well (eg [[5--10]])... Help! Someone?
Nope, it sucks. I had to write a bunch of checks in to one of my api scripts to prevent that problem.
1488967025
Tetsuo
Forum Champion
Hey Evynd. The roll20 dice roller absolutely can handle double negatives. You simply need to wrap the negative number in parenthesis like so: