diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/Item.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/Item.java index 1c81ac0c5..a2952cf80 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/Item.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/Item.java @@ -345,8 +345,8 @@ public class Item implements Bundlable { String name = name(); - if (levelKnown && level != 0) - name = Messages.format( TXT_TO_STRING_LVL, name, level ); + if (visiblyUpgraded() != 0) + name = Messages.format( TXT_TO_STRING_LVL, name, visiblyUpgraded() ); if (quantity > 1) name = Messages.format( TXT_TO_STRING_X, name, quantity ); diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java index 76af3b0fc..5c53f924c 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java @@ -113,7 +113,7 @@ public class Artifact extends KindofMisc { @Override public int visiblyUpgraded() { - return ((level()*10)/levelCap); + return levelKnown ? Math.round((level()*10)/(float)levelCap): 0; } //transfers upgrades from another artifact, transfer level will equal the displayed level @@ -134,16 +134,6 @@ public class Artifact extends KindofMisc { } } - @Override - public String toString() { - - if (levelKnown && level()/levelCap != 0) { - return Messages.format( TXT_TO_STRING_LVL, name(), visiblyUpgraded() ); - } else { - return name(); - } - } - @Override public String status() {