v0.3.0: buffed cape of thorns, now reduces damage from all types of attacks, but only deflects it back if the attacker is adjacent.

This commit is contained in:
Evan Debenham
2015-05-20 09:35:52 -04:00
committed by Evan Debenham
parent 772058af8d
commit ac6e8173e9
2 changed files with 13 additions and 10 deletions
@@ -895,11 +895,6 @@ public class Hero extends Char {
@Override
public int defenseProc( Char enemy, int damage ) {
CapeOfThorns.Thorns thorns = buff( CapeOfThorns.Thorns.class );
if (thorns != null) {
damage = thorns.proc(damage, enemy);
}
Earthroot.Armor armor = buff( Earthroot.Armor.class );
if (armor != null) {
damage = armor.absorb( damage );
@@ -932,6 +927,11 @@ public class Hero extends Char {
GLog.w("The pain helps you resist the urge to sleep.");
}
CapeOfThorns.Thorns thorns = buff( CapeOfThorns.Thorns.class );
if (thorns != null) {
dmg = thorns.proc(dmg, (src instanceof Char ? (Char)src : null), this);
}
int tenacity = 0;
for (Buff buff : buffs(RingOfTenacity.Tenacity.class)) {
tenacity += ((RingOfTenacity.Tenacity)buff).level;