diff --git a/core/src/main/assets/messages/items/items.properties b/core/src/main/assets/messages/items/items.properties index 4e387fdf4..f94f33855 100644 --- a/core/src/main/assets/messages/items/items.properties +++ b/core/src/main/assets/messages/items/items.properties @@ -89,7 +89,7 @@ items.armor.armor.inscribed=It is inscribed with a _%s._ items.armor.armor.cursed_worn=Because this armor is cursed, you are powerless to remove it. items.armor.armor.cursed=You can feel a malevolent magic lurking within this armor. items.armor.armor.not_cursed=This armor is free of malevolent magic. -items.armor.armor.seal_attached=The Warrior's broken seal is attached to this armor. +items.armor.armor.seal_attached=The Warrior's broken seal is attached to this armor, it is providing him up to _%d shielding_. items.armor.armor$glyph.glyph=glyph items.armor.armor$glyph.killed=%s killed you... diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/BrokenSeal.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/BrokenSeal.java index a95fed752..b25525d85 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/BrokenSeal.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/BrokenSeal.java @@ -67,6 +67,10 @@ public class BrokenSeal extends Item { this.glyph = glyph; } + public int maxShield( int armTier, int armLvl ){ + return armTier + armLvl + Dungeon.hero.pointsInTalent(Talent.IRON_WILL); + } + @Override public ItemSprite.Glowing glowing() { return glyph != null ? glyph.glowing() : null; @@ -191,8 +195,8 @@ public class BrokenSeal extends Item { } public synchronized int maxShield() { - if (armor != null && armor.isEquipped((Hero)target)) { - return armor.tier + armor.level() + ((Hero) target).pointsInTalent(Talent.IRON_WILL); + if (armor != null && armor.isEquipped((Hero)target) && armor.checkSeal() != null) { + return armor.checkSeal().maxShield(armor.tier, armor.level()); } else { return 0; } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java index 8e4555d57..03b0b8bcc 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java @@ -480,7 +480,7 @@ public class Armor extends EquipableItem { } else if (cursedKnown && cursed) { info += "\n\n" + Messages.get(Armor.class, "cursed"); } else if (seal != null) { - info += "\n\n" + Messages.get(Armor.class, "seal_attached"); + info += "\n\n" + Messages.get(Armor.class, "seal_attached", seal.maxShield(tier, level())); } else if (!isIdentified() && cursedKnown){ info += "\n\n" + Messages.get(Armor.class, "not_cursed"); }