V0.2.1 : Fixed a bug involving Ring of Tenacity (now rounds damage up, mainly so that hunger still hurts)
This commit is contained in:
parent
ad32c4d984
commit
56708b36aa
|
@ -842,7 +842,7 @@ public class Hero extends Char {
|
||||||
tenacity += ((RingOfTenacity.Tenacity)buff).level;
|
tenacity += ((RingOfTenacity.Tenacity)buff).level;
|
||||||
}
|
}
|
||||||
if (tenacity != 0) //(HT - HP)/HT = heroes current % missing health.
|
if (tenacity != 0) //(HT - HP)/HT = heroes current % missing health.
|
||||||
dmg *= Math.pow(0.9, tenacity*((float)(HT - HP)/HT));
|
dmg = (int)Math.ceil((float)dmg * Math.pow(0.9, tenacity*((float)(HT - HP)/HT)));
|
||||||
|
|
||||||
super.damage( dmg, src );
|
super.damage( dmg, src );
|
||||||
|
|
||||||
|
|
|
@ -18,8 +18,8 @@ public class RingOfTenacity extends Ring {
|
||||||
public String desc() {
|
public String desc() {
|
||||||
return isKnown() ?
|
return isKnown() ?
|
||||||
"When worn, this ring will allow the wearer to resist normally mortal strikes. " +
|
"When worn, this ring will allow the wearer to resist normally mortal strikes. " +
|
||||||
"The weaker the user becomes, the more resistant they will be to physical damage. " +
|
"The more injured the user is, the more resistant they will be to damage. " +
|
||||||
"A cursed ring will instead make it easier for the wearer to be executed." :
|
"A cursed ring will instead make it easier for enemies to execute the wearer." :
|
||||||
super.desc();
|
super.desc();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user