# Life Drain bug - premature damage reduction

**URL:** <https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233>\
**Category:** Support\
**Created:** [January 30, 2017, 4:49pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233 "2017-01-30T16:49:29Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![kynetarse](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/kynetarse/32/24815_2.png) [@kynetarse](https://community.gemsofwar.com/u/kynetarse)\
**Post date:** [January 30, 2017, 4:49pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/1 "2017-01-30T16:49:29Z")

</div>

**What you were expecting to happen, and what actually happened?**

When killing an enemy with the life drain trait via a spell that kills your own troop (ie Sacrificial Priest, Bombot), the troop with life drain will resurrect itself with 4 health after taking lethal damage, even if the lethal damage was above starting life + 4. Troops should not resurrect themselves.

EDIT: I now believe this is a case of damage being reduced prematurely. All damage should be applied and any overkill should only be reduced via displayed number only. Detailed in below post:

> [@Life Drain bug - premature damage reduction](http://community.gemsofwar.com/t/life-drain-bug-troops-resurrect-after-lethal-damage/19233/20):
>
> Revisiting this after taking a couple weeks off from exploration. I think I may have some better insight now on exactly what is occurring. I think the gist of the problem is that overkill damage is being reduced to exact number, rather than actually applying all damage at damage step and simply displaying a reduced number. Cast bombot Because bombot must die, damage must be calculated at this point Damage is calculated for life drain troop and improperly reduced to exact armor + hp Bombot di…

**What are the steps to make it happen again?**

Kill a life drain-traited troop (Anubite Warrior, Ghoul, Night Terror, etc) with lethal damage from Bombot or Sacrificial Priest

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [January 30, 2017, 4:56pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/2 "2017-01-30T16:56:41Z")

</div>

Old bug, should’ve been fixed a long time ago =/ Funny thing is that it happens almsot every time, but not every time.

---

<div class="post-metadata">

**Author:** ![kynetarse](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/kynetarse/32/24815_2.png) [@kynetarse](https://community.gemsofwar.com/u/kynetarse)\
**Post date:** [February 2, 2017, 7:48pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/3 "2017-02-02T19:48:48Z")

</div>

As an addendum to this, I’ve noticed that if the troop is in the first position and Bombot hits it with a skull before the AOE damage, the bug will not happen.

---

<div class="post-metadata">

**Author:** ![KrudlerTheHorse](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/krudlerthehorse/32/9505_2.png) [@KrudlerTheHorse](https://community.gemsofwar.com/u/KrudlerTheHorse)\
**Post date:** [February 2, 2017, 7:52pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/4 "2017-02-02T19:52:53Z")

</div>

If true that sounds like a unique insight on this nasty little bug !!!

---

<div class="post-metadata">

**Author:** ![Ozball](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/ozball/32/36110_2.png) [@Ozball](https://community.gemsofwar.com/u/Ozball)\
**Post date:** [February 3, 2017, 2:15am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/5 "2017-02-03T02:15:47Z")

</div>

Does this only happen if the skull damage kills the troop? or as long as it does damage even without killing it?

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 3, 2017, 2:28am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/6 "2017-02-03T02:28:44Z")

</div>

I think it has to deal at least the 4 skull damage it would’ve recovered. I haven’t tested it enough, though.

EDIT: I hit the first enemy with 3 skull damage from Bombot’s explosion and it died, despite its Life Drain… So I’m not quite right there.

---

<div class="post-metadata">

**Author:** ![Ozball](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/ozball/32/36110_2.png) [@Ozball](https://community.gemsofwar.com/u/Ozball)\
**Post date:** [February 3, 2017, 2:47am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/7 "2017-02-03T02:47:49Z")

</div>

My theory is this:

If the skull damage from the explosion kills the enemy, then it will die regardless of life drain.  
If the enemy dies from the Bombot’s “Destroy myself” then it will survive if it has life drain.

The core to this is the order in which the spell plays out. The wording is “Explode 2 random Gems. Deal [(Magic / 2) + 3] damage to all enemies, boosted by my Armor and destroy myself.” Going off the full stop after explode gems, I’m assume it resolves all damage then and there. and THEN it proceeds to do the Damage to all enemies from destroying itself, which only gets resolved after the whole effect (damage and self destruction) is done.

Part 1:  
Explode 2 gems.  
Traits fire if applicable.  
Deal any damage from skulls  
Traits fire if applicable.  
Collect mana from gems.  
Traits fire if applicable.  
Resolve any deaths.  
Traits fire if applicable.

Part 2:  
Deal damage to all enemies.  
Traits fire if applicable.  
Destroy myself.  
Traits fire if applicable.  
Resolve any deaths.  
Traits fire if applicable.

Since, in part 2, the traits fire before it checks for deaths, the Enemy sits at 0 HP after it’s dealt damage, and then it’s trait fires when the bombot dies, healing it up to 4 HP, so when it checks for deaths the enemy is not dead, but at 4 HP.

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 3, 2017, 2:51am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/8 "2017-02-03T02:51:21Z")

</div>

The enemy that died after receiving 3 skull damage had full health. I know it was 3 skull damage because the numbers pop separately.

EDIT: I mean, I think you’re on the right track, but that’s still not quite it, because it seems that any skull damage prevents Life Drain from activating.

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 3, 2017, 3:15am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/9 "2017-02-03T03:15:32Z")

</div>

Here’s a video of 2 troops with Life Drain. The Leader dies, the other doesn’t:

[![]( " - YouTube") ](https://www.youtube.com/watch?v=e5pJDqDvhG0)

Worth noticing: Bombot had total of 118 Armor+Life. It takes damage when it explodes, but it’s -1 and -107, or -117 and -0, and they show at the same time. With Spider Queen, the skull damage shows slightly earlier.

Maybe you can come up with another theory? =)

---

<div class="post-metadata">

**Author:** ![Ozball](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/ozball/32/36110_2.png) [@Ozball](https://community.gemsofwar.com/u/Ozball)\
**Post date:** [February 3, 2017, 3:17am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/10 "2017-02-03T03:17:09Z")

</div>

Yeah, that was why I was trying to clarify if it was a case of any skull damage or just lethal. And it does seem that any skull damage as you said, which makes my theory fall apart. Will take a look at the video in a couple minutes and see if I can come up with another theory.

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 3, 2017, 3:23am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/11 "2017-02-03T03:23:59Z")

</div>

(Just notice that I edited the numbers that show as Bombot’s received damaged in my reply above)

---

<div class="post-metadata">

**Author:** ![Ozball](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/ozball/32/36110_2.png) [@Ozball](https://community.gemsofwar.com/u/Ozball)\
**Post date:** [February 3, 2017, 3:27am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/12 "2017-02-03T03:27:15Z")

</div>

Ok new theory (based on the screenshot):

Spell fires  
The game calculates all the damage that will be going out (both from explosion and from the self destruct). But doesn’t apply it yet.

The game resolves the explosion of gems, dealing the damage to the first troop form skulls. But because it has also calculated the damage it will receive from the self destruct, it factors that in as well, and decides the troop is deal at the point the skull damage hits it.

At this point, the damage going out has been calculated to all troops, but only resolved on the first troop. So Night Terror is still on full life.

The game then applies the damage from the self destruct and then kills the bombot. The damage kills the Night Terror, but because the game doesn’t check for death until it’s done the whole effect, the Night Terror’s life drain triggers, bringing it back to life.

Short Version:  
The game calculates ALL damage at the start, but only applies it at the point at which the troop takes the damage. Because the spell is in two parts, the Spider Queen takes (all the) damage and dies before the second part of the spell resolves and the Bombot dies, and therefor not triggering Spider Queen’s Life Drain.

EDIT: A way to test this would be to have a case where both the first and second troop die to skull damage (if that’s possible… it might be a case of all skull damage goes to the first troop regardless…) and then a third troop die to the explosion, all with life drain, to see which survive and which don’t.

 ![](https://us1.discourse-cdn.com/flex019/uploads/gemsofwar/original/3X/d/8/d8daca0e4496e43bbdba66cbc699795a9f0cb61d.png)

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 3, 2017, 3:37am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/13 "2017-02-03T03:37:00Z")

</div>

The skull damage never hits the second troop, only if it’s because of a cascade, but that case doesn’t work for us because the spell calculations and resolutions would be over already.

But I like your theory. Could it be what caused a stunned IK to resurrect? I mean, calculate damage, checks that it would die, dead = no status effects, then trait had the chance to activate.

---

<div class="post-metadata">

**Author:** ![Ozball](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/ozball/32/36110_2.png) [@Ozball](https://community.gemsofwar.com/u/Ozball)\
**Post date:** [February 3, 2017, 3:42am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/14 "2017-02-03T03:42:36Z")

</div>

Could very well be. I haven’t run into IK very much and I don’t have his third trait, so I can’t really say I’ve seen it happen yet.

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 3, 2017, 3:55am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/15 "2017-02-03T03:55:19Z")

</div>

It was allegedly fix about a couple of months back, but I haven’t used many troops that cause stun.

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 4, 2017, 8:49pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/16 "2017-02-04T20:49:31Z")

</div>

Also, if Bombot’s explosion does NOT destroy skulls, the first troop survives with their Life Drain.

---

<div class="post-metadata">

**Author:** ![Grundulum](https://avatars.discourse-cdn.com/v4/letter/g/82dd89/32.png) [@Grundulum](https://community.gemsofwar.com/u/Grundulum)\
**Post date:** [February 5, 2017, 6:02am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/17 "2017-02-05T06:02:41Z")

</div>

Bombot causes several problems for the game, with the code in its current state. In addition to the Life Drain bug (which, according to testing I did a few months ago, does **not** affect Dwarven Slayer), there’s another peach I discovered recently: the death of Bombot triggers Kerberos’ Warg summon. For this to happen, the game needs to have (a) already cleared the dead enemy troops from the board (else there wouldn’t be a spot for the Warg), but (b) not resolved that Bombot died yet.

What I don’t understand is how Bombot’s death triggers both Life Drain (which must occur before enemy troops are cleared) and Gate Guardian (which must occur after enemy troops are cleared).

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 5, 2017, 6:20am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/18 "2017-02-05T06:20:54Z")

</div>

I noticed that as well. Usually, the warg spawns on top of the first troop that dies (when Warg dies, you’ll see the ghost of the previous troop)

---

<div class="post-metadata">

**Author:** ![MakoSipper](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/makosipper/32/1933_2.png) [@MakoSipper](https://community.gemsofwar.com/u/MakoSipper)\
**Post date:** [February 6, 2017, 1:48am UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/19 "2017-02-06T01:48:11Z")

</div>

Also, it just happened that the first troop survived after being hit by skulls and bombot’s explosion… It’s getting weird.

EDIT: Happened again. It happened when there was a Spider Queen both on position 1 and 2.

---

<div class="post-metadata">

**Author:** ![kynetarse](https://sea1.discourse-cdn.com/flex019/user_avatar/community.gemsofwar.com/kynetarse/32/24815_2.png) [@kynetarse](https://community.gemsofwar.com/u/kynetarse)\
**Post date:** [March 13, 2017, 4:32pm UTC](https://community.gemsofwar.com/t/life-drain-bug-premature-damage-reduction/19233/20 "2017-03-13T16:32:21Z")

</div>

Revisiting this after taking a couple weeks off from exploration. I think I may have some better insight now on exactly what is occurring. I think the gist of the problem is that overkill damage is being reduced to exact number, rather than actually applying all damage at damage step and simply _displaying_ a reduced number.

1. Cast bombot
2. Because bombot must die, damage must be calculated at this point
3. Damage is calculated for life drain troop and _improperly reduced_ to exact armor + hp
4. Bombot dies
5. Life drain triggers, granting +4 life
6. Improperly reduced damage applied; life drain troop survives because of the bonus

Of course, none of this still explains why single skull point of skull damage will disrupt the issue.
