From d8d54a4f3f8610cbaebbcdfebb56bd54fc966c27 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Tue, 19 Apr 2016 20:47:35 -0400 Subject: [PATCH] v0.3.5: bugfixes --- .../shatteredpixeldungeon/actors/buffs/Combo.java | 2 +- .../shatteredpixeldungeon/items/armor/Armor.java | 6 +++--- .../shatteredpixeldungeon/items/armor/ClassArmor.java | 7 +++++++ 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Combo.java b/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Combo.java index bbf62f8b7..6fe9638a0 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Combo.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Combo.java @@ -217,7 +217,7 @@ public class Combo extends Buff implements ActionIndicator.Action { dmg = Math.round(dmg*2.5f); break; case FURY: - dmg = Math.round(dmg*.4f); + dmg = Math.round(dmg*0.4f); break; } diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java index a0d523e8a..c8d01fde5 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java @@ -64,7 +64,7 @@ public class Armor extends EquipableItem { private int hitsToKnow = HITS_TO_KNOW; public Glyph glyph; - private boolean seal; + public boolean seal; public Armor( int tier ) { @@ -167,9 +167,9 @@ public class Armor extends EquipableItem { if (seal) Buff.affect(ch, BrokenSeal.WarriorShield.class).setArmor(this); } - public void affixSeal(BrokenSeal sigil){ + public void affixSeal(BrokenSeal seal){ this.seal = true; - if (sigil.level() > 0){ + if (seal.level() > 0){ //doesn't override existing glyphs, but doesn't create one either upgrade(glyph != null); } diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java index 1cb4044cc..7d272a394 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java @@ -20,8 +20,11 @@ */ package com.shatteredpixel.shatteredpixeldungeon.items.armor; +import com.shatteredpixel.shatteredpixeldungeon.Dungeon; +import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Buff; import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Invisibility; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero; +import com.shatteredpixel.shatteredpixeldungeon.items.BrokenSeal; import com.shatteredpixel.shatteredpixeldungeon.messages.Messages; import com.shatteredpixel.shatteredpixeldungeon.utils.GLog; import com.watabou.utils.Bundle; @@ -53,6 +56,10 @@ abstract public class ClassArmor extends Armor { switch (owner.heroClass) { case WARRIOR: classArmor = new WarriorArmor(); + classArmor.seal = armor.seal; + if (armor.seal && armor.isEquipped(owner)){ + Buff.affect(Dungeon.hero, BrokenSeal.WarriorShield.class).setArmor(classArmor); + } break; case ROGUE: classArmor = new RogueArmor();