btw, just a little preview. The next version will have two added formula functions: switch() and assign()
switch() will help to eliminate a bunch of if() statements:
if(r==1, 50,0) + if(r==2, 30, 0) + if(r==3, 10, 0) + if(r==4, 7, 0) + if(r==5, 3, 0)
can be expressed as:
switch(r, 1, 50, 2, 30, 3, 10, 4, 7, 5, 3, 0)
assign() will allow you to assign values to your own variables and use them. So, in the formula above I use the expression (round(bc / 10) * n) over and over. assign() will allow you to assign that value to your own variable and then reference the variable instead. (Multiple statements can actually already be used, by the way...)
assign("pp", (round(bc / 10) * n))
So, the formula in the previous post can be knocked down to:
assign("pointspool", round(bc / 10) * n);
if(n < 9, assign("percentage", switch(r, 1, .5, 2, .3, 3, .2, 0)));
if(n > 8 && n < 13, assign("percentage", switch(r, 1, .4, 2, .25, 3, .2, 4, .15, 0)));
if(n > 12, assign("percentage", switch(r, 1, .4, 2, .25, 3, .2, 4, .10, 5, .05, 0)));
pointspool * percentage;