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

Weird rounding problem in custom sheet

Hello everyone! [[floor((((@{Agility}+10)+20)/10)d10>7!)]] for some reason the above script outputs a number that was just rounded, not floored. ie. if the agility score is 37 it will out put it as though it were 40, which causes 1 more dice to be rolled that it is supposed to.  any help is appreciated, thank you.
1587663350

Edited 1587663507
Untested, but try moving the floor inward some to modify the number of dice: [[(floor(((@{Agility}+10)+20)/10)d10>7!)]] Also, any reason you are not combining +10 and +20 and using (@Agility+30)?
I tested that myself as one of the first changes, caused a syntax error in r20, and its a remnant of a previous itteration, base is 1 dice + mod, t1 skill is +2 dice, just a leftover
OK, let's try: [[ [[floor(((@{Agility}+10)+20)/10)]]d10>7!]]
1587665960

Edited 1587666061
That works for the first 2 but the 3rd tier gives advantage on the roll  [[{[[floor(((@{Agility}+10)+20)/10)]]d10>7!),[[floor(((@{Agility}+10)+20)/10)]]d10>7!)}kh1]] is not outputting anything on button press edit- solved, removed ) after the >7! Thank you for the help