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

nth root in macro?

1526239956

Edited 1526243697
I want to make a macro to count distance between to point which are in different height. This what I got now: /roll ?{Distance?}*2+?{Height?}*2 Can any one help to ad a  nth root to the macro?
1526242035

Edited 1526242066
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Raise it to the reciprocal. Square Root =n**(1/2) or  n**.5 Cube Root = n**(1/3) or n**.333
1526242216
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Keep in mind if you are doing this for D&D 5e, diagonals don't count, so the Pythagorean Theorem is h = greater of (a,b) . Or in plain language: range is the greater of the normal horizontal range, or the difference in altitude.
Thank you. I use Eucledian and it is for Mordheim and maybe for other skirmish war games.
1526244367
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
You're welcome. I only brought up 5e because it is the 600 pound gorilla. :)