v3.0.0: QoL adjustment to shard of oblivion, manual IDing now sets ready
This commit is contained in:
@@ -1393,11 +1393,12 @@ items.trinkets.saltcube.stats_desc=At its current level this trinket will increa
|
||||
|
||||
items.trinkets.shardofoblivion.name=shard of oblivion
|
||||
items.trinkets.shardofoblivion.desc=After stewing in the alchemy pot, this small shard of cursed metal has changed to be made of... nothing? Light seems to bend around it, and it hovers in place when you aren't holding it. The shard seems to be magically drawing power from your ignorance, so it's probably best to not think about it too much.
|
||||
items.trinkets.shardofoblivion.typical_stats_desc=Typically this trinket will increase the rate that enemies drop loot by 20%% for each piece of unidentified equipment you have equipped or recently used, to a max of _%d item(s)_. The shard will also prevent you from automatically identifying equipment, but can be used to manually identify items that are ready for it.
|
||||
items.trinkets.shardofoblivion.stats_desc=At its current level this trinket will increase the rate that enemies drop loot by 20%% for each piece of unidentified equipment you have equipped or recently used, to a max of _%d item(s)_. The shard will also prevent you from automatically identifying equipment, but can be used to manually identify items that are ready for it.
|
||||
items.trinkets.shardofoblivion.typical_stats_desc=Typically this trinket will increase the rate that enemies drop loot by 20%% for each piece of unidentified equipment you have equipped or recently used, to a max of _%d item(s)_. The shard will also prevent you from identifying equipment, but can be used to manually identify items that are ready for it.
|
||||
items.trinkets.shardofoblivion.stats_desc=At its current level this trinket will increase the rate that enemies drop loot by 20%% for each piece of unidentified equipment you have equipped or recently used, to a max of _%d item(s)_. The shard will also prevent you from identifying equipment, but can be used to manually identify items that are ready for it.
|
||||
items.trinkets.shardofoblivion.ac_identify=IDENTIFY
|
||||
items.trinkets.shardofoblivion.identify_prompt=Identify an Item
|
||||
items.trinkets.shardofoblivion.identify_ready=An item is ready to identify: %s.
|
||||
items.trinkets.shardofoblivion.identify_ready_worn=Your worn items are now all ready to identify.
|
||||
items.trinkets.shardofoblivion.identify_not_yet=That item isn't ready to be identified yet.
|
||||
items.trinkets.shardofoblivion.identify=You identify the item!
|
||||
items.trinkets.shardofoblivion$wandusetracker.name=Unidentified Wand Used
|
||||
|
||||
@@ -22,7 +22,6 @@
|
||||
package com.shatteredpixel.shatteredpixeldungeon.actors.blobs;
|
||||
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Assets;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Badges;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Dungeon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Awareness;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Buff;
|
||||
@@ -31,6 +30,7 @@ import com.shatteredpixel.shatteredpixeldungeon.effects.BlobEmitter;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.effects.Identification;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.effects.Speck;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.Item;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfIdentify;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.journal.Notes.Landmark;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.levels.Terrain;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
|
||||
@@ -77,8 +77,7 @@ public class WaterOfAwareness extends WellWater {
|
||||
if (item.isIdentified()) {
|
||||
return null;
|
||||
} else {
|
||||
item.identify();
|
||||
Badges.validateItemLevelAquired( item );
|
||||
ScrollOfIdentify.IDItem(item);
|
||||
|
||||
Sample.INSTANCE.play( Assets.Sounds.DRINK );
|
||||
emitter.parent.add( new Identification( DungeonTilemap.tileCenterToWorld( pos ) ) );
|
||||
|
||||
@@ -35,8 +35,12 @@ import com.shatteredpixel.shatteredpixeldungeon.items.artifacts.Artifact;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.bags.Bag;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.rings.Ring;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfRemoveCurse;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.trinkets.ShardOfOblivion;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.wands.Wand;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.Weapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.utils.GLog;
|
||||
import com.watabou.utils.Bundle;
|
||||
import com.watabou.utils.Random;
|
||||
|
||||
@@ -320,28 +324,52 @@ public class Belongings implements Iterable<Item> {
|
||||
|
||||
public void observe() {
|
||||
if (weapon() != null) {
|
||||
weapon().identify();
|
||||
Badges.validateItemLevelAquired(weapon());
|
||||
if (ShardOfOblivion.passiveIDDisabled() && weapon() instanceof Weapon){
|
||||
((Weapon) weapon()).setIDReady();
|
||||
} else {
|
||||
weapon().identify();
|
||||
Badges.validateItemLevelAquired(weapon());
|
||||
}
|
||||
}
|
||||
if (secondWep() != null){
|
||||
if (ShardOfOblivion.passiveIDDisabled() && secondWep() instanceof Weapon){
|
||||
((Weapon) secondWep()).setIDReady();
|
||||
} else {
|
||||
secondWep().identify();
|
||||
Badges.validateItemLevelAquired(secondWep());
|
||||
}
|
||||
}
|
||||
if (armor() != null) {
|
||||
armor().identify();
|
||||
Badges.validateItemLevelAquired(armor());
|
||||
if (ShardOfOblivion.passiveIDDisabled()){
|
||||
armor().setIDReady();
|
||||
} else {
|
||||
armor().identify();
|
||||
Badges.validateItemLevelAquired(armor());
|
||||
}
|
||||
}
|
||||
if (artifact() != null) {
|
||||
//oblivion shard does not prevent artifact IDing
|
||||
artifact().identify();
|
||||
Badges.validateItemLevelAquired(artifact());
|
||||
}
|
||||
if (misc() != null) {
|
||||
misc().identify();
|
||||
Badges.validateItemLevelAquired(misc());
|
||||
if (ShardOfOblivion.passiveIDDisabled() && misc() instanceof Ring){
|
||||
((Ring) misc()).setIDReady();
|
||||
} else {
|
||||
misc().identify();
|
||||
Badges.validateItemLevelAquired(misc());
|
||||
}
|
||||
}
|
||||
if (ring() != null) {
|
||||
ring().identify();
|
||||
Badges.validateItemLevelAquired(ring());
|
||||
if (ShardOfOblivion.passiveIDDisabled()){
|
||||
ring().setIDReady();
|
||||
} else {
|
||||
ring().identify();
|
||||
Badges.validateItemLevelAquired(ring());
|
||||
}
|
||||
}
|
||||
if (secondWep() != null){
|
||||
secondWep().identify();
|
||||
Badges.validateItemLevelAquired(secondWep());
|
||||
if (ShardOfOblivion.passiveIDDisabled()){
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready_worn"));
|
||||
}
|
||||
for (Item item : backpack) {
|
||||
if (item instanceof EquipableItem || item instanceof Wand) {
|
||||
|
||||
@@ -225,6 +225,10 @@ public class Armor extends EquipableItem {
|
||||
return super.identify(byHero);
|
||||
}
|
||||
|
||||
public void setIDReady(){
|
||||
usesLeftToID = -1;
|
||||
}
|
||||
|
||||
public boolean readyToIdentify(){
|
||||
return !isIdentified() && usesLeftToID <= 0;
|
||||
}
|
||||
@@ -483,7 +487,7 @@ public class Armor extends EquipableItem {
|
||||
if (usesLeftToID > -1){
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), name());
|
||||
}
|
||||
usesLeftToID = -1;
|
||||
setIDReady();
|
||||
} else {
|
||||
identify();
|
||||
GLog.p(Messages.get(Armor.class, "identify"));
|
||||
|
||||
@@ -253,6 +253,10 @@ public class Ring extends KindofMisc {
|
||||
return super.identify(byHero);
|
||||
}
|
||||
|
||||
public void setIDReady(){
|
||||
levelsToID = -1;
|
||||
}
|
||||
|
||||
public boolean readyToIdentify(){
|
||||
return !isIdentified() && levelsToID <= 0;
|
||||
}
|
||||
@@ -338,7 +342,7 @@ public class Ring extends KindofMisc {
|
||||
if (levelsToID > -1){
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), name());
|
||||
}
|
||||
levelsToID = -1;
|
||||
setIDReady();
|
||||
} else {
|
||||
identify();
|
||||
GLog.p(Messages.get(Ring.class, "identify"));
|
||||
|
||||
@@ -24,6 +24,11 @@ package com.shatteredpixel.shatteredpixeldungeon.items.scrolls;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Badges;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.effects.Identification;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.Item;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.armor.Armor;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.rings.Ring;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.trinkets.ShardOfOblivion;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.wands.Wand;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.Weapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.utils.GLog;
|
||||
@@ -45,10 +50,33 @@ public class ScrollOfIdentify extends InventoryScroll {
|
||||
protected void onItemSelected( Item item ) {
|
||||
|
||||
curUser.sprite.parent.add( new Identification( curUser.sprite.center().offset( 0, -16 ) ) );
|
||||
|
||||
|
||||
IDItem(item);
|
||||
}
|
||||
|
||||
public static void IDItem( Item item ){
|
||||
if (ShardOfOblivion.passiveIDDisabled()) {
|
||||
if (item instanceof Weapon){
|
||||
((Weapon) item).setIDReady();
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), item.name());
|
||||
return;
|
||||
} else if (item instanceof Armor){
|
||||
((Armor) item).setIDReady();
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), item.name());
|
||||
return;
|
||||
} else if (item instanceof Ring){
|
||||
((Ring) item).setIDReady();
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), item.name());
|
||||
return;
|
||||
} else if (item instanceof Wand){
|
||||
((Wand) item).setIDReady();
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), item.name());
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
item.identify();
|
||||
GLog.i( Messages.get(this, "it_is", item.title()) );
|
||||
|
||||
GLog.i(Messages.get(ScrollOfIdentify.class, "it_is", item.title()));
|
||||
Badges.validateItemLevelAquired( item );
|
||||
}
|
||||
|
||||
|
||||
@@ -250,6 +250,10 @@ public abstract class Wand extends Item {
|
||||
return this;
|
||||
}
|
||||
|
||||
public void setIDReady(){
|
||||
usesLeftToID = -1;
|
||||
}
|
||||
|
||||
public boolean readyToIdentify(){
|
||||
return !isIdentified() && usesLeftToID <= 0;
|
||||
}
|
||||
@@ -439,7 +443,7 @@ public abstract class Wand extends Item {
|
||||
if (usesLeftToID > -1){
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), name());
|
||||
}
|
||||
usesLeftToID = -1;
|
||||
setIDReady();
|
||||
} else {
|
||||
identify();
|
||||
GLog.p(Messages.get(Wand.class, "identify"));
|
||||
|
||||
@@ -134,7 +134,7 @@ abstract public class Weapon extends KindOfWeapon {
|
||||
if (usesLeftToID > -1){
|
||||
GLog.p(Messages.get(ShardOfOblivion.class, "identify_ready"), name());
|
||||
}
|
||||
usesLeftToID = -1;
|
||||
setIDReady();
|
||||
} else {
|
||||
identify();
|
||||
GLog.p(Messages.get(Weapon.class, "identify"));
|
||||
@@ -214,6 +214,10 @@ abstract public class Weapon extends KindOfWeapon {
|
||||
return super.identify(byHero);
|
||||
}
|
||||
|
||||
public void setIDReady(){
|
||||
usesLeftToID = -1;
|
||||
}
|
||||
|
||||
public boolean readyToIdentify(){
|
||||
return !isIdentified() && usesLeftToID <= 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user