Page 1 of 5 123 ... LastLast
Results 1 to 10 of 41

Thread: [Fixed] Decay heals undying

  1. #1
    Basic Member
    Join Date
    Jan 2012
    Posts
    1,128

    [Fixed] Decay heals undying

    Description: Using decay against enemy heroes heals undying

    Reproduction:
    1) Buy 6 vit boosters
    2) Level up decay
    3) Take around 500 damage
    4) Use decay against 5 enemy heroes


    Result: Suddenly, almost full HP
    Expected: Undying max HP - Current HP remains constant.

  2. #2
    Volunteer Moderator Kryil-'s Avatar
    Join Date
    May 2012
    Posts
    6,259
    Max HP - current HP should not be constant, but max HP / current HP.
    However, could be intended like armlet. Guessing though.

  3. #3
    Basic Member
    Join Date
    Jan 2012
    Posts
    1,128
    Yes it should be constant, mech up, don't spread bullshit, kthbye.

  4. #4
    Working as intended.
    Same behavior as OD banishment, but with AoE effect

  5. #5
    Basic Member
    Join Date
    Jan 2012
    Posts
    1,128
    Quote Originally Posted by RocketFingers View Post
    Working as intended.
    Same behavior as OD banishment, but with AoE effect
    Did you even test it? It should give undying 98*heroes affected HP, it gives him almost double of that.

  6. #6
    Volunteer Moderator Kryil-'s Avatar
    Join Date
    May 2012
    Posts
    6,259
    Hey, he has some manners.

    I can actually confirm this.
    I thought decay behaves like other stuff - well, my fault

    Warcraft 3:
    Test Undying had 904 of 1651 HP and used decay rank 4 onto 4 units (it steals 76 hp btw, 4*19).
    Afterwards I had 1208 of 1955 HP. The difference in HP between max and current stayed the same, percentage was therefore higher.

    Dota 2:
    Test Undying had 496 of 910 HP and used decay rank 4 onto 3 units.
    Afterwards I had 887 of 1138 HP while it should be 1138 - (910 - 496) = 724.
    The heal should be 228 but actually was 391.

    I had some regeneration, but that changes nothing. The heal is WAY to high.

  7. #7
    Basic Member ThoAppelsin's Avatar
    Join Date
    Jan 2012
    Posts
    2,888
    ^ So what it currently does on Dota 2 is:
    Heal the current HP by amount_of_the_heroes_inflicted * 4 * 19
    and then rescale the CurrentHP/MaxHP to its new value without changing the HP percentage.

    And this causes the CurrentHP get a secondary increase...

    And it should be like:
    Increase the current HP by amount_of_the_heroes_inflicted * 4 * 19
    and increase the max HP by amount_of_the_heroes_inflicted * 4 * 19 aswell, without touching the current HP.

    Haven't tested anything myself. I have only read the results Kyril- has provided.

  8. #8
    Basic Member shalafi's Avatar
    Join Date
    Nov 2011
    Posts
    659
    I explained it in the other thread:
    http://dev.dota2.com/showthread.php?t=65010

    And also found that level up strength isn't programmed correctly either (it should give you 19*STR current and maxHP, but in DotA2 it keeps the %HP). So maybe all of this should be consolidated in a big thread about HP/Mana, since there are like 5 bugs related to this.

    Does anyone know if base int also works like base STR in Wc3? (So you get 13*int current and max mana, or does it keep the %Mana)
    Last edited by shalafi; 12-07-2012 at 12:41 PM.

  9. #9
    Basic Member
    Join Date
    Jan 2012
    Posts
    1,128
    This is beyond that issue since neither max HP - current HP remains constant nor HP% remains constant, he gains HP% and max HP - current HP decreases.

    Yes, str behaves the same way as int relative to HP vs Mana.

  10. #10
    Basic Member ThoAppelsin's Avatar
    Join Date
    Jan 2012
    Posts
    2,888
    This issue is pretty much [Confirmed].
    I don't know what else is required... Maybe some screenshots?

    And I also retreat my assumption on my previous post. I've got a new one, and this time I'm pretty much sure it is all correct.


    W3 DotA version:
    Moment before the Undying casts his Decay on 4 dummy enemies:
    - Undying has 100/568 HP (17,6%)
    Moment after the Undying casts his Decay on 4 dummy enemies:
    - Undying has 404/872 HP (46,3%)

    Steps to obtain these values:
    1. Decay hits 4 heroes
    2. 4 str is transfered per hero
    3. Each str is evaluates to 19 HP
    4. 4 * 4 * 19 = 304 HP in total
    5. Increase MaxHP and CurrentHP individually
    6. (100 + 304) / (568 + 304) HP
    7. 404/872 HP


    Dota 2 version:
    Moment before the Undying casts his Decay on 4 dummy enemies:
    - Undying has 100/568 HP (17,6%)
    Moment after the Undying casts his Decay on 4 dummy enemies:
    - Undying has 546/872 HP (62,6%)

    Steps to obtain these values (this will be crazy):
    1. Decay hits 4 heroes
    2. 4 str is transfered per hero
    3. Each str is evaluates to 19 HP
    4. Dota 2: "Decay hits all of them at once, but noooo, I will take them all seperately, and one by one, and I'll do it in such a wrong way that it will be damn hard for you to find it how!"
    5. 4 * 19 = 76 HP per hero
    6. Increase only the CurrentHP first
    7. (100 + 76) / 568 HP
    8. 176/568 HP
    9. Now, calculate (MaxHP + 76) / MaxHP = 1,1338...
    10. Multiply both MaxHP and the CurrentHP with this value
    11. (176 * 1,1338...) / (568 * 1,1338...) HP
    12. 199,55.../644 HP
    13. Now, don't you ever round it like normal people do, get the int(), get the flat value
    14. 199/644 HP
    15. Repeat the steps above 3 more times...
    16. (199 + 76) / 644 HP
    17. 275/644 HP
    18. ??? / (644 + 76) HP
    19. 307,45.../720 HP
    20. 307/720 HP
    21. 383/720 HP
    22. ??? / (720 + 76) HP
    23. 423,43.../796 HP
    24. 423/796 HP
    25. 499/796 HP
    26. 546,64.../872 HP
    27. 546/872 HP


    If I do not ever round, and use exact values for the calculation, the result is: 548,408.../872 HP
    If I round using the conventional method, the result is: 549,930.../872 HP

    So, the basic formula for single Decay instance is:

    NewCurrentHP = int((CurrentHP + 76) / MaxHP * (MaxHP + 76))
    NewMaxHP = MaxHP + 76

    And if Decay inflicts more than one hero, then it does this again and again.
    I don't know anything about programming, but making it like this should be a lot harder than simply increasing x and y by z.
    This is too complicated and wrong.

    And I want to add that each time the "Increase only the CurrentHP first" occurs, if the CurrentHP hits the quota, then you'll end up with MaxHP after the process is done.
    So, if you get damaged for ~70 HP, you can get fully healed by casting decay on a single hero target.
    And ~250 missing HP (not 4*76, since it is complicated) gets fully healed when you hit 4 heroes at once.
    And getting fully healed is never possible on DotA, unless you were already at MaxHP of course...




    Edit after a long while:

    I got bored and wrote some lines for Python to calculate the output for the bugged version I explained above.
    There it goes:

    def f(x, y, z):
    _ a = 0
    _ _ while a < z:
    _ _ _ x += 76
    _ _ _ x = x * y ** -1
    _ _ _ y += 76
    _ _ _ x = int(x * y)
    _ _ _ if x > y:
    _ _ _ _ x = y
    _ _ _ a += 1
    _ print str(x) + "/" + str(y) + " HP"

    x: Current HP
    y: Max HP
    z: Number of Decay buffs applied

    I doubt that anyone will ever see this, but if anyone does, I know it could be a lot shorter. I just wanted to make it easy to understand, aswell.
    Last edited by ThoAppelsin; 01-11-2013 at 09:24 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •