PDA

View Full Version : Statistics Questions



Preaplanes
2013-05-10, 10:42 PM
I was wondering if there's a frequented board for general RPG-based statistics questions. If not, consider this one.

My question is how to maximize statistics on a fairly simple system

I'm given 10 points in a combat system. Each point can be put into attack, defense, or HP.

Each point of Attack and Defense gives you 1d6
Each point of HP gives you 10hp
There is a minimum of 2 damage per attack, so long as your attack roll is over 1
Combat between two characters is simultaneous, each taking an amount of damage per turn. When you hit 0, you lose.

Assuming equal points, what stats 1 on 1 would give the highest win chance? If you increase in points allowed by "leveling up", is there an easy ratio or formula to follow?

Kornaki
2013-05-10, 10:48 PM
You never really explained what combat is... Attack and Defense give 1d6 what? What are you rolling when you attack and how is damage decided?

Preaplanes
2013-05-10, 10:50 PM
You never really explained what combat is... Attack and Defense give 1d6 what? What are you rolling when you attack and how is damage decided?

Raw damage, and subtracting the damage.

I roll 8 attack, you roll 5 defense, you take 3 damage.

I roll 1 attack, you take 1 no matter your roll due to the minimum damage rule.

I roll 3 attack, you roll 4 defense, you take 2 damage due to the minimum damage rule.

How HP works is nigh-universal for gaming.

Astral Avenger
2013-05-10, 11:23 PM
Raw damage, and subtracting the damage.

I roll 8 attack, you roll 5 defense, you take 3 damage.

I roll 1 attack, you take 1 no matter your roll due to the minimum damage rule.

I roll 3 attack, you roll 4 defense, you take 2 damage due to the minimum damage rule.

How HP works is nigh-universal for gaming.

so if I have points allocated as 5 attack, 4 defense, 1 hp I would:
attack with 5d6 (same roll for to-hit and damage)
defend with 4d6
have 10 hp

how does rolling a 1 work for attack with more than 1 die (is it impossible with 2d6)?
Minimum damage rule is what, 1 damage with an attack roll of 1, 2 damage otherwise?

Preaplanes
2013-05-10, 11:37 PM
so if I have points allocated as 5 attack, 4 defense, 1 hp I would:
attack with 5d6 (same roll for to-hit and damage)
defend with 4d6
have 10 hp

how does rolling a 1 work for attack with more than 1 die (is it impossible with 2d6)?
Minimum damage rule is what, 1 damage with an attack roll of 1, 2 damage otherwise?

Exactly right.

Slipperychicken
2013-05-10, 11:45 PM
Assuming equal points, what stats 1 on 1 would give the highest win chance?

Whatever you do, you might want this site (http://anydice.com/), type in "output Xd6" twice or "output Xd6-Yd6", for attack and damage, and hit "View: graph" to see nice graphs of it.

I'm guessing that each turn, combatants roll attack vs. defense, and do nothing else? My gut tells me that attack and hp are going to be a lot more useful than defense, since you take damage no matter what.

It... seems like it would depend a lot on what you're up against. You could probably try building few "sample" combatants (one high Defense, one high-hp, one high attack, one balanced) and go off that.


Once you had a combatant built, to determine if one is superior to the other, assume each die returns the average/expected result of 3.5, figure out how much damage (AD=average damage=[(3.5)*(attack-defense)], if attack=<defense then AD=2) that means to each side per turn-cycle, and see how many turns (T) it takes for each side's hit points (H) to hit zero (T=H/AD).

To determine win chance... you'd need the probability of each result of the opposed roll (attack-defense<2, attack-defense=2, attack-defense=3, and so on), which the site gives you conveniently. Then... the only thing I can think of is you'd create a "probability tree" and use each result as a branch, then copy-paste it a bunch of times because the probability of each result happening doesn't change round-to-round. After you've outlined every possible "path" the battle could take and the probability of each one, you sum up the ones in which you win, and that's your win chance. That's horrifying and horribly inefficient, but you could probably write a program to do it.


Or at least I think that's how it would work. Someone with better stats skills than I could probably make this a little easier.

Chronos Flame
2013-05-11, 12:57 AM
So I didn't run the numbers (I would be willing to bet I will at some bored moment in the future) but my gut reaction for "Powergaming" would be (assuming min1 per stat) 2Att (To insure 2 damage. Maybe one would be enough), 1Def, and 7HP. Each HP gives a solid 10 where each def gives an effective 3.5 HP per round.
In 1on1 you are going back and forth so HP is unquestionably better than Def until more poeple have the option of all attacking you. Having low points in attack is trickier, but it makes every point an opponent has in Def useless due to the minimum damage rule.
I think you could definitely go more balanced in Att and HP, but 2-1-7 would be my best bet.

Preaplanes
2013-05-11, 12:04 PM
So I didn't run the numbers (I would be willing to bet I will at some bored moment in the future) but my gut reaction for "Powergaming" would be (assuming min1 per stat) 2Att (To insure 2 damage. Maybe one would be enough), 1Def, and 7HP. Each HP gives a solid 10 where each def gives an effective 3.5 HP per round.
In 1on1 you are going back and forth so HP is unquestionably better than Def until more poeple have the option of all attacking you. Having low points in attack is trickier, but it makes every point an opponent has in Def useless due to the minimum damage rule.
I think you could definitely go more balanced in Att and HP, but 2-1-7 would be my best bet.

Well, I'd assume HP has a minimum of 1 (otherwise you'd be dead), and it's impossible to win without any ATK, but I see no reason why DEF would necessitate a minimum.

Of course, at a certain point I assume Damage Per Round starts to add up faster than HP would.

Bryn
2013-05-11, 02:51 PM
I'm in a PbP game (Godhood 3) running at the moment with a very similar system. I solved it (https://dl.dropboxusercontent.com/u/12456893/Godhood%203/RevisedProbabilityCalculator.nb) in Mathematica for probabilities of win/lose/draw using absorbing Markov chains.

It's not quite the same system, as 0 is the floor to damage rather than 2, and the characters had 20*integer HP instead of 10*integer. This would not be too difficult to change...

Here (https://dl.dropboxusercontent.com/u/12456893/Godhood%203/ManipCalc.cdf) is a CDF (http://www.wolfram.co.uk/cdf-player/) calculator to find the probability of winning/losing/drawing on the Godhood 3 system. If I have time I'll modify it to adapt the peculiarities of this system, add in a calculation of how many rounds the fight is expected to take, and give the option of a surrender point instead of enforcing a fight to the death. This has not been tested against a Monte-Carlo simulation, but the results look plausible.

Some explanation of how this works, and the speed improvements I needed to make, is here (http://www.giantitp.com/forums/showpost.php?p=15146044&postcount=120).

In our version of the system, we found (http://www.giantitp.com/forums/showpost.php?p=15145304&postcount=95) that the players who dumped HP for either attack or defence were most powerful in the sense of most likely to win in fights against the other players. I expect that would be exaggerated by reduced HP, but also reduced by the minimum damage. We found characters who formed rock-paper-scissors-like loops, with each one likely to win against one and not win against the other.

Given that, I think optimising this system heavily depends on what builds your likely opponents have chosen.

Exediron
2013-05-11, 03:16 PM
I programmed a quick and dirty Visual Basic program to compare results, and what it tells me is that:

(All results are against a hypothetical A3,D3,H4 opponent)

7,1,2 = 70.1% wins
1,7,2 = 0% wins
2,1,7 = 10.0% wins
1,2,7 = 14.4% wins
7,2,1 = 42.3% wins
2,7,1 = 0% wins

I realize this is a crude methodology (only testing one set of numbers in different arrays), but basically what the program is telling us is:

Attack is by far the greatest determiner of success
Hit Points are useful
Defense is a bum stat and you should avoid it

The two arrays with maxed out defense lost every time because of the minimum damage ceiling, whereas the arrays with maxed out attack killed their opponents before their hit points became an issue. My recommendation therefore, from the standpoint of optimization, is to put the bare minimum in everything else and all of the rest into attack.

neonchameleon
2013-05-11, 03:46 PM
Defence is a dud stat as you've set it up. If attack beats defence then the attacker's margin matters. If defence wins, it still loses and the defensive margin is irrelevant. Attack > Defence so the defensive stat is hp.

If we assume anyone smart goes in with a defence of 1, then due to multiplier effects the optimal all attack/hit point ratio is almost certainly 5 attack, 4hp (for an effective 4/4 against strong threats - the optimal default is almost always the square).

On the other hand if the NPCs all have high defences, the metagame changes quite a lot, initially favouring an attack of 6 for an average defence of 3. But at some point defence will rise to the point it's not worth overcoming (I really can't be bothered to calculate this but would guess the tipping point is around 5 dice for defence) and the optimal attack will become 1, grinding away at the target 1 5/6hp per attack and relying on your bank of 80 hp to stay alive long enough to win.

Oh, and average damage for 1d attack vs defence is (1*5+2*4+3*+6*1+24*2)/36 = 79/36 =2 7/36 or 1 13/66 times (1.2 times for all practical purposes) as much damage as minimum damage.

And even with high defence being useless, there's still a rock/paper/scissors game happening, but not enough of one. The basic winner is the person whose (hp*(attack - enemy defence)*) is higher. At 5/1/4, your "combat potential" against another person with 5/1/4 is 16. Your combat potential against someone with 4/3/3 is 8, and theirs is 9 - but I'm not sure who'd win because of the defender not getting advantage from good defence completely negating or even overwhelming bad attack. And 4/3/3 will struggle against 1/4/5 or 1/5/4 whereas 5/1/4 should beat either hollow.

* This formula doesn't hold when defence approaches attack; the minimum value of attack-defence is just over 0.5 and it's significantly higher than this when the number of dice are equal on each side or even within 1 of each other.

Now I come to think about it 3/4/3 might do even better against 5/1/4 than 4/3/3 - but 4/3/3 is superior to 3/4/3 in head to heads. And I think 6/1/3 might be optimal even if it's fractionally weaker than 5/1/4 in personal matchups as it should beat both 4/3/3 and 3/4/3. We're way into metagame considerations here.

Emmerask
2013-05-11, 04:03 PM
I programmed a quick and dirty Visual Basic program to compare results, and what it tells me is that:

(All results are against a hypothetical A3,D3,H4 opponent)

7,1,2 = 70.1% wins
1,7,2 = 0% wins
2,1,7 = 10.0% wins
1,2,7 = 14.4% wins
7,2,1 = 42.3% wins
2,7,1 = 0% wins

I realize this is a crude methodology (only testing one set of numbers in different arrays), but basically what the program is telling us is:

Attack is by far the greatest determiner of success
Hit Points are useful
Defense is a bum stat and you should avoid it

The two arrays with maxed out defense lost every time because of the minimum damage ceiling, whereas the arrays with maxed out attack killed their opponents before their hit points became an issue. My recommendation therefore, from the standpoint of optimization, is to put the bare minimum in everything else and all of the rest into attack.

In theory yes, though if someone knows the meta used by others ie the 7,1,2
then using a 2,7,1 will beat that.
It will take 7,1,2 an avg of 10 hits to kill 2,7,1 while 2,7,1 will need 6 hits

Exediron
2013-05-11, 05:06 PM
In theory yes, though if someone knows the meta used by others ie the 7,1,2
then using a 2,7,1 will beat that.
It will take 7,1,2 an avg of 10 hits to kill 2,7,1 while 2,7,1 will need 6 hits

That flaw is because my numbers were originally run on a PvE assumption, whereas on a better reading of the OP this question is supposed to address PvP.

In a 1 on 1 fight I don't think there is any such thing as a single best array; it depends entirely too much on the exact array of your opponent. For every given array there is one that can kill it.

Even if you have 9/0/1 - the highest theoretical damage output - it can be defeated by 3/0/7 nearly 100% of the time. However, 3/0/7 is easily destroyed by 2/3/5 on average (although with more variability). 2/3/5 is also usually going to kill 9/0/1.

The best I think you could hope for is an array with the best chance of winning against a given randomly generated opponent. If human intelligence is involved then it becomes more of a game of psychology and knowing your enemy.

The Walrus
2013-05-22, 12:11 AM
MARKOV CHAINS? BAH! WALRUS HULK SMASH PUNY STATISTICS PROBLEM WITH BRUTE FORCE!

http://i1286.photobucket.com/albums/a609/TheWalrusOne/battlestats_zps98e368ef.jpg

I calculated the number of possible stat distributions to be 45. After writing a brief java program and manually coding in all of the distributions, I had them do a round robin tournament with 10000 fights for each match up, and printed the number of wins out of 440000 battles for each distribution. Although there is no clear winner, a hierarchy does seem to emerge. Defense doesn't appear to be totally useless, but none of the top 8 have it as their highest stat. Note how much lower 3/4/3 is than 4/3/3 and 3/3/4. Interestingly, the most balanced point spread appears to be the best spread overall, with the previous 3 distributions taking 9th, 2nd, and 4th place respectively.

WALRUS HULK ANGRY AT LACK OF CLEAR ANSWERS! WALRUS HULK ANALYZE THE MATCH-UPS OF TOP DISTRIBUTIONS IN DEPTH ON LATER DATE!

Edge of Dreams
2013-05-22, 12:31 AM
Thanks for the analysis, Walrus, but....


After writing a brief java program and manually coding in all of the distributions,

Oi, this hurts. As one software developer to another, why, why, why would you manually enumerate the different stat distributions rather than writing a loop to generate them?

TuggyNE
2013-05-22, 12:58 AM
Oi, this hurts. As one software developer to another, why, why, why would you manually enumerate the different stat distributions rather than writing a loop to generate them?

Because he was hulking out? :smalltongue:

Also, seems to me a good Python/JS/Ruby script woulda done the job easier *grumblegrumble*

NichG
2013-05-22, 03:16 PM
There's likely a bit of an RPS element to this calculation, in that Build A > Build B > Build C > Build A. Since there's only 45 possible distributions, you could do the full 45x45 fight matrix with row order sorted by overall win rate or something. That would answer the question of whether there's a single ultimate build (the best guy beats all other guys > 50% of the time) or if there's some subset of ultimate builds that have an RPS relationship with eachother.

Waar
2013-05-22, 06:06 PM
In order to maximize your chance to win you (obviously) want to stay alive as long as possible and deal as much damage as possible. Had the defence stat not existed this would have been achieved with 50% dmg and 50% Health (since there is no base hp or damage and both increase linearly they are both of equal value). now defence do exist but is less valuable than attack or healththe best bet is probably attack and hp > 33% each, defence < 33 % which would give us Three probable options 4,2,4. 4,3,3. and 3,3,4
(se walruz/Hulk smash for other options :smallsmile:)

Additionally there are some metagame aspects that are relevant, when facing a someone with defence it is probably best if your attack score is far away from their defence score (making it less usefull)

Another idea is letting approximately atk score-def score=HP score (se 5,2,3 in Walrus post)since in a def free enviroment akt=HP is the winner. A more advanced method is PC atk - other def = PC HP and staying far away from other atk - PC def = other HP.

Note: there are probably better methods than mine out there.

AttilaTheGeek
2013-05-22, 07:56 PM
MARKOV CHAINS? BAH! WALRUS HULK SMASH PUNY STATISTICS PROBLEM WITH BRUTE FORCE!

WALRUS HULK ANGRY AT LACK OF CLEAR ANSWERS! WALRUS HULK ANALYZE THE MATCH-UPS OF TOP DISTRIBUTIONS IN DEPTH ON LATER DATE!

I just burst out laughing.