PathOfBuildingCommunity / PathOfBuildingCommunity/PathOfBuilding

Incorrect Leech calculations

Offen
#2,741 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

bug
Vorherrschende Sprache
Lua
Sterne
5.4k
Forks
2.4k
Ø Merge
1 T. 12 Std.
Gemergte PRs (30 T.)
26

Beschreibung

Hello. This is not really a "bug" but I couldn't find another place to properly submit this issue.

I have been messing around with the leech modifiers (life leech, but maybe the others are working the same way), and the values that PoB shows, I think they are incorrect.

I'll set up an example, if you don't mind:

Some facts:

  • Each instance of life leech is capped at 10% of maximum life.
  • Each instance of leech recovers life at a rate of 2% of maximum life.
  • The maximum recovery per second from all instances of life leech is capped at 20% of maximum life.
  • There is no limit to how many leech instances are active, but rather the limits are given by the 3 values above.

Deductions we can make:

  • Assuming we never reach full life, each instance of life leech that reached its cap of 10% of maximum life expires after 5 seconds, due to the fact that the recovery of this instance is at a rate of 2% of maximum life, and the total instance is 10% of maximum life, so after 5 seconds we have recovered the full 10%.
  • We would need 10 instances of life leech, recovering 2% of maximum life each, to reach the cap of 20% of maximum life recovered per second.

What I think is wrong:

Lets say I have 7,166 life. Therefore, each instance of life leech is capped at 716.6 life (10%). Each instance of life leech recovery rate is capped at 143.22 life per second (2%). After 5 seconds, the total amount recovered from this instance of life leech is 716.6, the whole instance of 10% of my maximum life.

The problem is the following: if I take a node like the one called "Two Handed Melee Damage and Life Leech Speed", which modifies the value "Increased Recovery per Second from Life Leech", the total amount of life recovered from an instance of life leech changes according to PoB shown in the "Life Leech/Gain per Hit" value, and it shouldn't change.

This node should just be modifying the rate at which I recover life (the 2%), and this node is really not modifying the total amount a life leech instance can recover (the 10%). So all this node should do is make it so that I am recovering life faster, but in the end, the total amount recovered should still be the same, which also means that the life leech instance does no longer last 5 seconds, but less, because since I recover life faster, I reach the total amount faster.

Putting in some numbers using this specific node that I mentioned: the node says "60% increased Recovery per Second from Life Leech". This means that instead of 2%, I am now recovering 3.2% maximum life per second. The instance is still a total of 10% of maximum life, so the duration of the instance is 3.125 seconds, and not 5 seconds as it was previously.

But according to PoB, I am now recovering more life per life leech instance, and that is incorrect. I think the reason why this value is incorrect is because the default duration value of 5s per life leech instance is still being 5s, and not being modified by the fact that the cap of the instance is still 10% of maximum life and I am reaching that cap faster now, so the instance in reality lasts less.

This is the build I was working on when figuring all this out:
https://pastebin.com/CTbn9C1A

I may be wrong, but I don't think I am. Let me know if there is any need for clarification.

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Es ist keine Quelldatei und kein Test angegeben. Beginne damit, das Life-Leech-Beispiel aus dem Issue mithilfe des verlinkten Pastebin-Builds zu reproduzieren, und verfolge anschließend die Berechnung, die den Wert „Life Leech/Gain per Hit“ erzeugt. Als erledigt gilt die Aufgabe, wenn eine erhöhte Wiederherstellung die Wiederherstellungsrate und -dauer verändert, ohne die insgesamt pro Life-Leech-Instanz wiederhergestellte Menge zu erhöhen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
lua
Bereich
backend
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.