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

7th Sea, 2nd Edition. Grouped successes of 10+

In 7th Sea, 2nd Edition you roll d10 dice and "buy raises" which cost either 10 or 15 from dice sums.  Raises are just another way of saying successes, but in this case success is not a target number for each die, but rather a target number for groups of dice to sum up to. Is there a way, api or anything, to have the game figure out the number of raises you are able to buy, and just list the number of successes? I would love to be able to input the number of dice rolled, such as "7d10" and have it show me the value of the 7 dice, and then say "3 successes" or "4 successes."  It also happens that sometimes dice explode on a 10 if the character is in certain situations, but I'm hoping to be able to add the "!" into the macro if the character gains exploding dice.  Thanks for the help! Example of "cost 10 raises" Roll 8d10 2,4,4,5,7,8,9,10 Raise 1: 2+8=10 (10 is >=10) Raise 2: 4+9=13 (13 is >=10) Raise 3: 4+7=11 (11 is >=10) Raise 4: 10 (The die that rolled 10 is a raise by itself, being of sufficient value >=10) 5 is the remaining die, and is a "hanging die" because it is not being used Number of raises costing 10 = 4 Example of "cost 15 raises" Roll 8d10 2,4,4,5,7,8,9,10 Raise 1: 5+10=15 (15 is >=15) Raise 2: 2+4+9=15 (15 is >=15) Raise 3: 7+8=15 (15 is >=15) 4 is the remaining die, and is a "hanging die" because it is not being used Number of raises costing 15 = 3
1519568126

Edited 1519575132
You would definitely be able to do this in the API, although it is not a trivial solution.  You would need to design an algorithm to do the combination of the set of dice that finds the greatest number of {threshold} values you can make with a set of dice. Which is not too difficult but might be easiest with advanced algorithm design techniques. This problem looks like a recursive divide-and-conquer solution to me. After that, all that is left is to handle input/output. If this ends up getting moved to API and you are still interested I could help design your algorithm to sort the dice.
1519581227

Edited 1519581557
That would be amazing Briland.  I didn't know there was a seperate api forum. (I'm new to the forums) I'm reposting the question there now.  Thanks for the advice that it would need to be api!