ffxiv-teamcraft / simulator

Crafting simulator for FINAL FANTASY XIV
MIT License
24 stars 18 forks source link

Floor Repairs #14

Closed ayyaruq closed 4 years ago

ayyaruq commented 4 years ago

This likely needs a bunch of double checking and testing because I'm not sure I got all those /100's correct.

The formula should be returning a non-floored base effect, which multiplies by condition before flooring. This should be the formula itself, stats adjustment, level adjustment, and condition modifier. This is floored and then buffs and efficiency are applied before a final flooring, for a total of 2 floors (rather than the old 3).

I'm not sure if the baseQuality/baseProgress methods get weird with return types on a float vs integer, but the math here should be correct now. The bug mostly causes a 1-3 discrepancy in progress or quality and is most easily seen under Ingenuity.

codecov[bot] commented 4 years ago

Codecov Report

Merging #14 into master will decrease coverage by 0.05%. The diff coverage is 23.07%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #14      +/-   ##
==========================================
- Coverage   28.71%   28.66%   -0.06%     
==========================================
  Files          52       52              
  Lines        1400     1399       -1     
  Branches      131      131              
==========================================
- Hits          402      401       -1     
  Misses        996      996              
  Partials        2        2
Impacted Files Coverage Δ
src/model/tables.ts 100% <ø> (ø) :arrow_up:
src/model/actions/other/delicate-synthesis.ts 0% <0%> (ø) :arrow_up:
src/model/actions/quality-action.ts 0% <0%> (ø) :arrow_up:
src/model/actions/progress-action.ts 84.21% <100%> (ø) :arrow_up:
src/model/actions/crafting-action.ts 74.28% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 7fded89...cef5ac6. Read the comment docs.