ds3optimizer icon indicating copy to clipboard operation
ds3optimizer copied to clipboard

Unreliable behavior when equip load strictly equals weight threshold.

Open Corollax opened this issue 9 years ago • 8 comments

At 40 vigor, player characters have 80 equipment load available. The tool reports 56.0 weight setups as satisfying the default 0.7 "fast roll" criteria, but Dark Souls 3 gives these players a slow roll.

Intuitively, the default setting should provide a fast roll for the 70% burden setting, and the tool should mirror the game's test "less than" criteria, rather than using "less than or equal to".

EDIT: It appears that this edge case is inconsistent, and depends on From's rounding algorithm. They should be using integer math if they're going to be testing inequalities, but this is very evidently not the case.

Corollax avatar Jun 14 '16 01:06 Corollax

Are you 100% sure that literal equal condition never works? I'll check myself in a bit, but it seems odd that I haven't encountered this during the months I've been using it. I don't doubt your claim, maybe there's odd rounding going on.

3dots avatar Jun 15 '16 22:06 3dots

Sry, accidentally closed.

3dots avatar Jun 15 '16 22:06 3dots

I did some more testing. Unfortunately, the 70.0 result is inconsistent. I have two setups that reach 56.0 units of weight with my 80 load allowance. One can fast roll. The other cannot.

If I select strictly pieces that are representable without loss in binary arithmetic (i.e. pieces with weight evenly divisible by 0.5), I get a fast roll. Maybe that helps.

Corollax avatar Jun 16 '16 12:06 Corollax

roflmao, did they write their own floating arithmetic?

3dots avatar Jun 16 '16 22:06 3dots

Hey, is there any chance my Data sets are wrong? There were rumors on r/darksouls3 about possible armor weight changes a few days back.

3dots avatar Jun 17 '16 01:06 3dots

I suppose it's possible, but it'd be unrelated to this issue. Your calculator gave me exactly the weight the game calculated -- but the result of that calculation was inconsistent on the fast roll threshold, depending on the pieces I used to get there.

Sorry if I'm being unhelpful or too critical. I really like your tool. Thanks for providing it.

Corollax avatar Jun 20 '16 12:06 Corollax

Ok, my suspicion is that they may be using float instead of double floating point precision. Can you post exact equipment choices you had that conflict with the <70% rule? If we try to compute the weight fraction using floats maybe that will reveal something.

3dots avatar Jun 24 '16 16:06 3dots

For my testing, I equipped weapons with whole-integer weight until I had exactly 6.0 units of my 70% threshold left. So if you have 10 vitality (50 load), that's 35.0 units available. I spent 29.0 units of weight using only equipment that weighed a multiple of 1.0 units, leaving 6.0 units.

With rings and gauntlets, I then spent my remaining weight:

  • Four Clutch rings + Gloves of Thorns:
    • (4 x 0.8) + 2.8 => FAST roll
  • Four Stoneplate rings + Sunless Gauntlets:
    • (4 x 0.6) + 3.6 => FAST roll
  • Three " boosting" rings + Sage ring + Dark Gauntlets:
    • (4 x 0.7) + 3.2 => SLOW roll

" boosting" = Morne's Ring, Young Dragon Ring, Great Swamp Ring

Corollax avatar Jul 05 '16 16:07 Corollax