From f898df2c22edafccad0593c575721c31f654f41e Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Fri, 6 May 2016 16:39:31 -0400 Subject: [PATCH] v0.3.5a: fixed warrior's seal working incorrectly with class armor --- .../shatteredpixeldungeon/items/armor/Armor.java | 2 +- .../shatteredpixeldungeon/items/armor/ClassArmor.java | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java index cf432d83d..97057146c 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java @@ -55,7 +55,7 @@ public class Armor extends EquipableItem { private static final int HITS_TO_KNOW = 10; private static final String TXT_TO_STRING = "%s :%d"; - private static final String AC_DETACH = "DETACH"; + protected static final String AC_DETACH = "DETACH"; public int tier; diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java index 34178278c..ca53d79d8 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java @@ -29,6 +29,7 @@ import com.watabou.utils.Bundle; import java.util.ArrayList; +//FIXME: this should be upgradeable, fix in 0.4.0 abstract public class ClassArmor extends Armor { private static final String AC_SPECIAL = "SPECIAL"; @@ -69,7 +70,8 @@ abstract public class ClassArmor extends Armor { classArmor = new HuntressArmor(); break; } - + + classArmor.level(armor.level()); classArmor.STR = armor.STR; classArmor.DR = armor.DR(); @@ -98,6 +100,7 @@ abstract public class ClassArmor extends Armor { @Override public ArrayList actions( Hero hero ) { ArrayList actions = super.actions( hero ); + actions.remove( AC_DETACH ); if (hero.HP >= 3 && isEquipped( hero )) { actions.add( AC_SPECIAL ); }