Page 1 of 1

Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 31 Jul 2016, 03:28
by Glidias
For any TROS-like games using Dice pools and TNs, here's a quick JS /html webpage I did up to help determine probability of successes (both discrete and total) when dealing with both contested/uncontested rolls. It has all the individual roll stats to help Great for gamemasters/players/developers, etc. Also, it can act as a useful shortcut in rolling with a single Math.random() against an aggregated floating point ratio/percentage probability instead of counting each successful dice individually. Enjoy!

http://glidias.github.io/Asharena/demos ... ility.html

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 31 Jul 2016, 14:35
by higgins
Oh, this is really nice! I've been using an ancient excel spreadsheet, but it doesn't tell you anything about opposed rolls. This one definitely does. :)

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 31 Jul 2016, 15:05
by thirtythr33
I have this spreadsheet I made to do the same thing.

https://www.dropbox.com/s/20b11zxy902g3 ... .xlsx?dl=0

Mine can also handle flat Obs for either party as well, and I've been trying to figure out how to do exploding dice.

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 31 Jul 2016, 15:18
by higgins
Exploding dice are always the stuff of nightmares for any kind of probability charts.

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 01 Aug 2016, 06:32
by Glidias
To get average Mean Margin of Favor (favoring which side), you can calculate it quickly using:
( (Chance to succeed at BS>=1) + (Chance to succeed at BS>=0)) /2.

So, a value of 50% favors neither side. (even though this may favor a particular side in certain actual game contexts.)

Would probably add that as well into the calculator. But strategically, most characters would want to adopt the necessary dice to deal a positively safe/ideal BS (bonus success/margin of success), depending on what the character is trying to achieve.

Also (slightly) useful to add would be Chance for Tie Occuring:
= (Chance to succeed at BS>=1) - (Chance to succeed at BS>=0).

Had to setup a calculator like this to help in developing an AI bot for TROS/TROSLikes.


Regarding TROS/TROSlikes, I thought exploding dice is only used conditionally when rolling against TNs greater than 10 in order to stack over it's current value ? Ie. If i roll a 10, i won't get an extra dice to roll, i just re-roll back the same dice (only if necessary) to stack an additional value over it existing tenth in the hope of meeting the necessary TN for that dice. Thus, to get the probability of a single dice roll's success given a TN, it is simply a 0(1) method that can be used.

Code: Select all

	public static inline function getTNSuccessProbForDie(tn:Int):Float {
		return tn < 11 ? (10-tn+1) / 10 :  ( 1- ( tn - Math.floor((tn)/10)*10 ) / 10 )   *  Math.pow(0.1, Math.floor(tn/10) );
	}
I haven't really validated this fully to see it's entirely true, but I did some tests particularly for TNs greater than 10, 20+s, 30s, etc. and the results are correct.

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 01 Aug 2016, 07:40
by thirtythr33
In BoB ties always go to the attacker and every dice explodes (by allowing you to roll another dice and add it to the pool. TN doesn't go over 10 in BoB).

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 19 Aug 2016, 04:38
by Glidias
Currently working on a AI bot calculator to help detect "favorable/sensible" manuevers/combos that are possible to use against given opponent.

http://glidias.github.io/Asharena/demos ... itest.html

Above is a test-bed to test-execute static functions remotely. Usually the last 3 functions on the leftmost column are key for the AI to help detect possible "favorable/sensible-enough" moves. If AI is severely disadvantage in CP and does not have any good openings, a null /false value is return. (would likely have to stick to a "desperate" manuever fallback option)

What's left? Still need to add in stuff like armor/target-zone consideration (aim at weakest spot) and some of the remaining combos like whether it's good to steal initiative or not (and some of the other mixed/double attack combos.., and when it's possible to switch to a Rota/Counter, or when to use Block Open and strike when dealing with weak strikes (besides the current typical defensive Disarm manuever) ).

On the right column, if you scroll down to bottom, a static variable B_BS_REQUIRED_DMG can be adjusted to simulate armor value barrier. When up against armored opponents with a >1BS required to deal damage, AI may switch to beat/bind-and-strike manuevers (instead of regular damaging attack manuevers) to lower the opponent CP pool first, if it deems unable to penetrate through armor of opponent yet. It will determine at what point it's "reasonable" enough to try an Alpha Strike or Coup-de-grace killing blow manuever with the entire dice pool being used as well, or whether a CP-budgeted damaging strike is viable enough.

Remember to include equipments for both characters prior to testing the static functions.

Of course, the actual AI will have to predictively determine all these combos' avaialbility at the start of every round, and whether he should approach the battle with an offensive/defensive intent together with any related stance bonuses, etc. in order to best maximise his overall strategy. Currently, there is no avenue put in place to "bluff" the AI with regards to your revealed combat pool, but that can be added later once the core static methods are up.

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 19 Aug 2016, 05:11
by higgins
Glidias wrote:positively safe/ideal BS
Glidias wrote:Chance to succeed at BS
This is completely offtopic and feel free to call me immature, but I simply have to wonder whether making these abbreviations funny was a conscious choice on the designers' part. :lol:

Re: Dice Pool Probability Calculator/Aggregator for TROS-Like games

Posted: 19 Aug 2016, 05:32
by Glidias
lol, Song of swords..blame it on it... MS, MOS, ....