Alya-N / C-Hero-Calc

PvE Solver for Cosmos Quest (Last Update: Archers and the Eternals)
10 stars 6 forks source link

Reflect occurs after healing in the game, but not in calc. #7

Closed Alya-N closed 5 years ago

Alya-N commented 5 years ago

This leads to a particular issue, where a Guy's reflect from w30 combined with Hawking do not kill Tiny:1000, despite Tiny having 1370 HP, and Guy dealing 1370 damage, as Tiny heals himself before taking Guy's hit. That leads to false positives, such as below. I'll work on moving all reflect related functions to after healing occurs, but I'm posting this as a warning, until I fix it. Example of a false positive can be seen here:

Solution for [Followers: 1,547,547,000 | jackoknight:1000 tiny:1000 w30 w30 w30 <==]:
  [Followers:       0 | shygu:99 pokerface:81 ashygu:88 drhawking:99 masterlee:88 guy:19 <==]

  852 Fights simulated.
  Total Calculation Time: 5
  Calc Version: 3.2.2.0d

Battle Replay (Use on Ingame Tournament Page):
eyJ3aW5uZXIiOiJVbmtub3duIiwibGVmdCI6IlNvbHV0aW9uIiwicmlnaHQiOiJJbnN0YW5jZSIsImRhdGUiOjE1NDQ0OTc5MjgsInRpdGxlIjoiUHJvcG9zZWQgU29sdXRpb24iLCJzZXR1cCI6Wy01NywtMTExLC0xMjAsLTEwMywtMTA0LC0xMzIsLTU3LC0xMTEsLTEyMCwtMTAzLC0xMDQsLTEzMiwtNTcsLTExMSwtMTIwLC0xMDMsLTEwNCwtMTMyLC01NywtMTExLC0xMjAsLTEwMywtMTA0LC0xMzIsLTU3LC0xMTEsLTEyMCwtMTAzLC0xMDQsLTEzMl0sInNoZXJvIjpbMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCw5OSwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCw5OSw4OCwwLDAsMCwwLDAsMCw4MSwwLDAsMCwwLDAsMCwwLDAsODgsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDE5LDAsMCwwLDAsMF0sInBsYXllciI6Wy01NCwtMywxMTksMTE5LDExOSwtMSwtNTQsLTMsMTE5LDExOSwxMTksLTEsLTU0LC0zLDExOSwxMTksMTE5LC0xLC01NCwtMywxMTksMTE5LDExOSwtMSwtNTQsLTMsMTE5LDExOSwxMTksLTFdLCJwaGVybyI6WzAsMTAwMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMTAwMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDAsMCwwLDBdfQ==

After Turn 1:
Left:
  Damage:   98
  Health: -889  762  333  447  269  220
Right:
  Damage: 1370
  Health:  646  744  744    0 1218

After Turn 2:
Left:
  Damage:  723
  Health: -889 -124  333  447  269  220
Right:
  Damage:  886
  Health:  -77  301  744    0 1218

After Turn 3:
Left:
  Damage:  510
  Health: -889 -124 -553  447  269  220
Right:
  Damage:  886
  Health:  -77 -209  744    0 1218

After Turn 4:
Left:
  Damage: 1164
  Health: -889 -124 -553 -439  269  220
Right:
  Damage:  886
  Health:  -77 -209 -420    0 1218

After Turn 5:
Left:
  Damage: 1395
  Health: -889 -124 -553 -439 -654  220
Right:
  Damage:  923
  Health:  -77 -209 -420    0 -177
Alya-N commented 5 years ago

I've updated the master branch with the fix. https://github.com/Alya-N/C-Hero-Calc/compare/3.2.2.0cBackup...Alya-N:master If new issues arise, I'll revert to 3.2.2.0c