v0.7.0: added a new "not identified, but not cursed" state for items
This commit is contained in:
parent
754b629034
commit
b7d966fe0f
|
@ -413,6 +413,8 @@ public class Armor extends EquipableItem {
|
|||
info += "\n\n" + Messages.get(Armor.class, "cursed");
|
||||
} else if (seal != null) {
|
||||
info += "\n\n" + Messages.get(Armor.class, "seal_attached");
|
||||
} else if (!isIdentified() && cursedKnown){
|
||||
info += "\n\n" + Messages.get(Armor.class, "not_cursed");
|
||||
}
|
||||
|
||||
return info;
|
||||
|
|
|
@ -125,13 +125,14 @@ public class Artifact extends KindofMisc {
|
|||
@Override
|
||||
public String info() {
|
||||
if (cursed && cursedKnown && !isEquipped( Dungeon.hero )) {
|
||||
|
||||
return desc() + "\n\n" + Messages.get(Artifact.class, "curse_known");
|
||||
|
||||
|
||||
} else if (!isIdentified() && cursedKnown && !isEquipped( Dungeon.hero)) {
|
||||
return desc()+ "\n\n" + Messages.get(Artifact.class, "not_cursed");
|
||||
|
||||
} else {
|
||||
|
||||
return desc();
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -160,13 +160,14 @@ public class Ring extends KindofMisc {
|
|||
String desc = isKnown()? desc() : Messages.get(this, "unknown_desc");
|
||||
|
||||
if (cursed && isEquipped( Dungeon.hero )) {
|
||||
|
||||
desc += "\n\n" + Messages.get(Ring.class, "cursed_worn");
|
||||
|
||||
} else if (cursed && cursedKnown) {
|
||||
|
||||
desc += "\n\n" + Messages.get(Ring.class, "curse_known");
|
||||
|
||||
|
||||
} else if (!isIdentified() && cursedKnown){
|
||||
desc += "\n\n" + Messages.get(Ring.class, "not_cursed");
|
||||
|
||||
}
|
||||
|
||||
return desc;
|
||||
|
|
|
@ -29,7 +29,6 @@ import com.shatteredpixel.shatteredpixeldungeon.effects.Flare;
|
|||
import com.shatteredpixel.shatteredpixeldungeon.effects.particles.ShadowParticle;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.Item;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.armor.Armor;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.bags.Bag;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.Weapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.utils.GLog;
|
||||
|
@ -74,15 +73,15 @@ public class ScrollOfRemoveCurse extends InventoryScroll {
|
|||
|
||||
boolean procced = false;
|
||||
for (Item item : items) {
|
||||
if (item != null && item.cursed) {
|
||||
if (item != null) {
|
||||
item.cursedKnown = true;
|
||||
procced = item.cursed;
|
||||
item.cursed = false;
|
||||
procced = true;
|
||||
}
|
||||
if (item instanceof Weapon){
|
||||
Weapon w = (Weapon) item;
|
||||
if (w.hasCurseEnchant()){
|
||||
w.enchant(null);
|
||||
w.cursed = false;
|
||||
procced = true;
|
||||
}
|
||||
}
|
||||
|
@ -90,18 +89,9 @@ public class ScrollOfRemoveCurse extends InventoryScroll {
|
|||
Armor a = (Armor) item;
|
||||
if (a.hasCurseGlyph()){
|
||||
a.inscribe(null);
|
||||
a.cursed = false;
|
||||
procced = true;
|
||||
}
|
||||
}
|
||||
if (item instanceof Bag){
|
||||
for (Item bagItem : ((Bag)item).items){
|
||||
if (bagItem != null && bagItem.cursed) {
|
||||
bagItem.cursed = false;
|
||||
procced = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (procced) {
|
||||
|
|
|
@ -183,8 +183,11 @@ public abstract class Wand extends Item {
|
|||
|
||||
desc += "\n\n" + statsDesc();
|
||||
|
||||
if (cursed && cursedKnown)
|
||||
if (cursed && cursedKnown) {
|
||||
desc += "\n\n" + Messages.get(Wand.class, "cursed");
|
||||
} else if (!isIdentified() && cursedKnown){
|
||||
desc += "\n\n" + Messages.get(Wand.class, "not_cursed");
|
||||
}
|
||||
|
||||
return desc;
|
||||
}
|
||||
|
|
|
@ -105,6 +105,8 @@ public class MeleeWeapon extends Weapon {
|
|||
info += "\n\n" + Messages.get(Weapon.class, "cursed_worn");
|
||||
} else if (cursedKnown && cursed) {
|
||||
info += "\n\n" + Messages.get(Weapon.class, "cursed");
|
||||
} else if (!isIdentified() && cursedKnown){
|
||||
info += "\n\n" + Messages.get(Weapon.class, "not_cursed");
|
||||
}
|
||||
|
||||
return info;
|
||||
|
|
|
@ -272,6 +272,8 @@ abstract public class MissileWeapon extends Weapon {
|
|||
info += "\n\n" + Messages.get(Weapon.class, "cursed_worn");
|
||||
} else if (cursedKnown && cursed) {
|
||||
info += "\n\n" + Messages.get(Weapon.class, "cursed");
|
||||
} else if (!isIdentified() && cursedKnown){
|
||||
info += "\n\n" + Messages.get(Weapon.class, "not_cursed");
|
||||
}
|
||||
|
||||
info += "\n\n" + Messages.get(MissileWeapon.class, "distance");
|
||||
|
|
|
@ -85,10 +85,10 @@ public class CryptRoom extends SpecialRoom {
|
|||
prize.upgrade();
|
||||
//curse the armor, unless it has a glyph
|
||||
if (!prize.hasGoodGlyph()){
|
||||
prize.cursed = prize.cursedKnown = true;
|
||||
prize.inscribe(Armor.Glyph.randomCurse());
|
||||
}
|
||||
}
|
||||
prize.cursed = prize.cursedKnown = true;
|
||||
|
||||
return prize;
|
||||
}
|
||||
|
|
|
@ -117,7 +117,8 @@ public class PoolRoom extends SpecialRoom {
|
|||
prize = Generator.randomArmor((Dungeon.depth / 5) + 1);
|
||||
}
|
||||
} while (prize.cursed || Challenges.isItemBlocked(prize));
|
||||
|
||||
prize.cursedKnown = true;
|
||||
|
||||
//33% chance for an extra update.
|
||||
if (Random.Int(3) == 0){
|
||||
prize.upgrade();
|
||||
|
|
|
@ -134,6 +134,7 @@ public class TrapsRoom extends SpecialRoom {
|
|||
prize = Generator.randomArmor((Dungeon.depth / 5) + 1);
|
||||
}
|
||||
} while (prize.cursed || Challenges.isItemBlocked(prize));
|
||||
prize.cursedKnown = true;
|
||||
|
||||
//33% chance for an extra update.
|
||||
if (Random.Int(3) == 0){
|
||||
|
|
|
@ -375,8 +375,12 @@ public class WndBag extends WndTabbed {
|
|||
bg.ra = +0.3f;
|
||||
bg.ga = -0.15f;
|
||||
} else if (!item.isIdentified()) {
|
||||
bg.ra = 0.2f;
|
||||
bg.ba = 0.2f;
|
||||
if (item.cursedKnown){
|
||||
bg.ba = 0.3f;
|
||||
} else {
|
||||
bg.ra = 0.3f;
|
||||
bg.ba = 0.3f;
|
||||
}
|
||||
}
|
||||
|
||||
if (item.name() == null) {
|
||||
|
|
|
@ -88,6 +88,7 @@ items.armor.armor.defense=It is augmented to enhance _defense._
|
|||
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$glyph.glyph=glyph
|
||||
items.armor.armor$glyph.killed=%s killed you...
|
||||
|
@ -140,6 +141,7 @@ items.artifacts.alchemiststoolkit.ac_brew=BREW
|
|||
items.artifacts.artifact.cannot_wear_two=You cannot wear two of the same artifact.
|
||||
items.artifacts.artifact.equip_cursed=The artifact painfully binds itself to you.
|
||||
items.artifacts.artifact.curse_known=You can feel a malevolent magic lurking within the artifact.
|
||||
items.artifacts.artifact.no_curse=This artifact is free of malevolent magic.
|
||||
items.artifacts.artifact.need_to_equip=You need to equip your artifact to do that.
|
||||
|
||||
items.artifacts.capeofthorns.name=cape of thorns
|
||||
|
@ -549,6 +551,7 @@ items.rings.ring.known=This is a %s
|
|||
items.rings.ring.identify=You are now familiar enough with your ring to identify it. It is a %s.
|
||||
items.rings.ring.cursed_worn=Because this ring is cursed, you are powerless to remove it.
|
||||
items.rings.ring.curse_known=You can feel a malevolent magic lurking within this ring.
|
||||
items.rings.ring.no_curse=This ring is free of malevolent magic.
|
||||
|
||||
items.rings.ringofaccuracy.name=ring of accuracy
|
||||
items.rings.ringofaccuracy.desc=This ring increases your focus, reducing your enemy's ability to dodge your attacks. A cursed ring will instead make it easier for enemies to evade your attacks.
|
||||
|
@ -1100,6 +1103,7 @@ items.weapon.weapon.excess_str=Because of your excess strength, you will deal up
|
|||
items.weapon.weapon.incompatible=Interaction of different types of magic has negated the enchantment on this weapon!
|
||||
items.weapon.weapon.cursed_worn=Because this weapon is cursed, you are powerless to remove it.
|
||||
items.weapon.weapon.cursed=You can feel a malevolent magic lurking within this weapon.
|
||||
items.weapon.weapon.not_cursed=This weapon is free of malevolent magic.
|
||||
items.weapon.weapon.faster=It is augmented to enhance _speed._
|
||||
items.weapon.weapon.stronger=It is augmented to enhance _damage._
|
||||
items.weapon.weapon.enchanted=It has a _%s._
|
||||
|
|
Loading…
Reference in New Issue
Block a user