A Short Primer on AW Luck Mechanics

Talk about Advance Wars DS. Debate, laugh, cry, argue about everything to do with our favourite tag game here.
Post Reply
User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD
Contact:

A Short Primer on AW Luck Mechanics

Post by Xenesis » Mon Jan 18, 2016 5:27 pm

This is something I'm going to clean up and eventually turn into a site article, but I thought I should post the basics here.

Advance Wars 2 and Dual Strike fundamentally use the same calculations for rolling dice.

The RNG affects a lot of things, but the most obvious one is damage variance in the game. This is pretty obvious when you see a 55% attack between Infantry Vs Infantry for example, and some will take 5HP Damage, while others will take 6HP damage. Each unit works with 10 HP on what is equivalently a decimal scale, so the highest unit HP is 10.0 HP (10), while the lowest is 0.1 HP (1).

So, an attack that inflicts 55% on an attack, at its simplest will inflict 5.5 damage at minimum. Each standard CO has a basic luck of 10, which means that the attack can inflict 5.5 to 6.4 damage, so 5HP to 6HP of damage inflicted.

But why, 6.4 (+0.9) instead of 6.5? - this is to do with how the game calculates the value for a luck range.

The game takes an input of a random number (this is a 32-bit value, so a random value from 0 to 4294967295), then takes the luck range and calculates the remainder of this value. So for a luck range of 10, the potential remainder value will be a value of 0 to 9. For a luck range of 15, the potential remainder values range from 0 to 14.

So for that 55% attack, the inflicted damage will range from 55% to 64% with a standard CO. This is before any other changes, like defence, terrain etc.

In terms of calculating more complex values, the order of operations is as follows:

1. Base Damage
2. Multiply Firepower Bonuses/Penalties
3. Add Luck Rolls
4. Multiply by HP Scaling
5. Multiply Target Defence Bonuses/Penalties (CO Defence + Terrain Defence)

So this means a few things:
1. A CO's Firepower does not affect the range of luck on a target.
2. A Unit's HP scales the luck range on a target.
3. Higher defence means less luck damage taken by a target.

For example, Using AW2 Max's Tank Vs. AW2 Sturm's Tank on Plains:

1. Base Damage: 55%
2. Max's Firepower Bonus: +20%, Damage: 66%
3. Max has a standard luck range, so Damage: 66% to 75%
4. Units are at full HP, so Damage: 66% to 75%
5. Sturm's Defence is +20%, Sturm's Terrain Defence is +10% for a total of +30% Defence. Final Damage is 46% to 52%.

For COs with non-standard luck ranges, the same rules still apply. For example, AWDS Nell's Infantry Vs AWDS Kanbei's Infantry on a City:

1. Base Damage: 55%
2. No bonus firepower D2D: 55%
3. Nell has a luck range of 20, Damage: 55% to 74%
4. Units are at full HP, so 55% to 74%
5. Kanbei's Defence is +20%, City is +30% for a total of +50%. Final Damage is 27% to 37%. So, Nell will inflict 2-3 HP damage to the target.

For a more extreme example: AWDS Nell using Lady Luck, with the Luck Skill and with a Tag Partner of Rachel Vs Kanbei's Infantry on a City:

1. Base Damage: 55%
2. Nell Has SCOP: 60%
3. Lady Luck has a luck range of 100, Luck adds 10 and a 3-Star tag with Rachel adds 15 for a total of 125. Damage: 60% to 184%
4. Full HP, still 60% to 184%
5. Kanbei's Defence on a City is +50%. Final Damage is 30% to 92%, So Nell can inflict between 3 and 9 HP of damage to the target.

For COs who have bad luck (Flak, Sonja and Jugger), there is an extra random roll for the damage. The bad luck is rolled separately to the good luck and the results are added together. This has the result of bell curving the results a bit around the centre of their values, making the extremities less likely. e.g. for AW2 Flak to roll maximum damage, he has to roll a +14 Good Luck and a -0 Bad Luck.

For an example: AW2 Flak Vs. AW2 Andy on a Road, Infantry vs. Infantry
1. Base Damage: 55%
2. No Firepower Bonuses: 55%
3. Flak has 15 Luck and 10 Bad luck. Damage: 46% to 69%
4. Full HP, still 46% to 69%
5. Andy has no defence, so the luck roll is unchanged. Final Damage is 46% to 69%, Flak can inflict between 4 HP and 6 HP damage to the target.

And a couple of more complex examples: Jugger using Overclock Vs. Von Bolt on Plains, Infantry vs. Infantry, Both Infantry are at 6 HP

1. Base Damage: 55%
2. Jugger has COP, +10%: Damage: 60%
3. Overclock has 55 Luck and 25 Bad luck, Damage: 36% to 114%
4. The Infantry has 6 HP, so 21% to 68%
5. Von Bolt has +10% Defence, Plains give 6% (6 HP) for +16%, Final Damage: 17% to 57%. Jugger's infantry can inflict 1 HP to 5 HP.

AWDS Sonja using Counter Break Vs Grimm on a Headquarters
1. Base Damage: 55%
2. Sonja has SCOP, +10% damage: Damage: 60%
3. Sonja has 10 Luck and 5 Bad Luck, Damage: 56% to 69%
4. Both units are at full health, 56% to 69%
5. Grimm has -20% defence, HQ vs Counter Break gives +10% (4* - 3* ) for a total of -10%. Final Damage: 61% to 75%. Sonja's infantry can do 6-7 HP of damage.

The standard ranges for luck are as follows:

:skill: Standard CO Base: +10
:skillluck: Luck Skill: +10
:tagaffinity: One-Star Tag Team: +5
:tagaffinity: :tagaffinity: Two-Star Tag Team: +10
:tagaffinity: :tagaffinity: :tagaffinity: Three Star Tag Team: +15

Stats for COs who have altered luck rolls:
:nellds: (AW2/AWDS)
:skill: +20
:power: +60
:super: +100

:rachel:
:power: +40

:sonjads: (AW2)
:skill: :power: :super: +10, -10

:sonjads: (AWDS)
:skill: :power: :superds: +10, -5

:flakds: (AW2)
:skill: +15, -10
:power: +40,-20
:super: +80,-30

:flakds: (AWDS)
:skill: +25,-10
:power: +50,-20
:superds: +90,-40

:jugger:
:skill: +30,-15
:power: +55,-25
:superds: +95,-45

Anyone have any obvious suggestions for something that would improve this?
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

User avatar
ALAKTORN
Location: Italy

Re: A Short Primer on AW Luck Mechanics

Post by ALAKTORN » Mon Jan 18, 2016 7:29 pm

Rachel’s COP gives her more luck. Other than that, it looks correct.

User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD
Contact:

Re: A Short Primer on AW Luck Mechanics

Post by Xenesis » Mon Jan 18, 2016 7:31 pm

ALAKTORN wrote:Rachel’s COP gives her more luck. Other than that, it looks correct.
Oops, knew I forgot something. Fixed.
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD
Contact:

Re: A Short Primer on AW Luck Mechanics

Post by Xenesis » Sat Jan 30, 2016 12:14 pm

I put together some anydice graphs for people who want to visualise what the various powers look like:

AWDS Day to Days
AWDS CO Powers
AWDS Super CO Powers

AW2 Day to Days
AW2 CO Powers
AW2 Super CO Powers
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

User avatar
Dragonite
Rank: My face is beaming.
Location: the netherlands(mostly)

Re: A Short Primer on AW Luck Mechanics

Post by Dragonite » Tue Feb 02, 2016 10:47 pm

Does HP reduction/enemy defense also get reduce the size of the bad luck roll? They probably do.. That means the bad luck CO's get more consistent under bad conditions, right?

Also, Sonja's ''weakness'' in AWDS is even more non-existent now. The normal luck roll can deal with her chance to whiff most of the time, and even if she does it's usually so small it will only matter with the 100% matchups. Did AW1 roll only once? Her bad luck range is higher the the good luck range in that game..

User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD
Contact:

Re: A Short Primer on AW Luck Mechanics

Post by Xenesis » Tue Feb 02, 2016 11:17 pm

Dragonite wrote:Does HP reduction/enemy defense also get reduce the size of the bad luck roll? They probably do.. That means the bad luck CO's get more consistent under bad conditions, right?
Yeah, although that's basically an artifact of the reduced damage overall - they're still less consistent than other COs who don't have a negative luck roll.
Also, Sonja's ''weakness'' in AWDS is even more non-existent now. The normal luck roll can deal with her chance to whiff most of the time, and even if she does it's usually so small it will only matter with the 100% matchups. Did AW1 roll only once? Her bad luck range is higher the the good luck range in that game..
AW1 is indeed a single roll. And they didn't even include the luck penalty in her AWDS Dossier, guess that's how small they felt it was.
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

Post Reply

Who is online

Users browsing this forum: Data [Bot] and 1 guest