v0.7.4: wand of living earth now requires a target to grant armor
This commit is contained in:
parent
ed45c37e0a
commit
f3e2c60d46
|
@ -76,12 +76,16 @@ public class WandOfLivingEarth extends DamageWand {
|
||||||
}
|
}
|
||||||
|
|
||||||
RockArmor buff = curUser.buff(RockArmor.class);
|
RockArmor buff = curUser.buff(RockArmor.class);
|
||||||
if (buff == null && guardian == null){
|
if (ch == null){
|
||||||
|
armorToAdd = 0;
|
||||||
|
} else {
|
||||||
|
if (buff == null && guardian == null) {
|
||||||
buff = Buff.affect(curUser, RockArmor.class);
|
buff = Buff.affect(curUser, RockArmor.class);
|
||||||
}
|
}
|
||||||
if (buff != null){
|
if (buff != null) {
|
||||||
buff.addArmor(level(), armorToAdd);
|
buff.addArmor(level(), armorToAdd);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//shooting at the guardian
|
//shooting at the guardian
|
||||||
if (guardian != null && guardian == ch){
|
if (guardian != null && guardian == ch){
|
||||||
|
@ -148,16 +152,18 @@ public class WandOfLivingEarth extends DamageWand {
|
||||||
processSoulMark(ch, chargesPerCast());
|
processSoulMark(ch, chargesPerCast());
|
||||||
ch.damage(damage, this);
|
ch.damage(damage, this);
|
||||||
|
|
||||||
} else {
|
|
||||||
Dungeon.level.press(bolt.collisionPos, null, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (guardian == null) {
|
if (guardian == null) {
|
||||||
curUser.sprite.centerEmitter().burst(MagicMissile.EarthParticle.ATTRACT, 8 + level() / 2);
|
curUser.sprite.centerEmitter().burst(MagicMissile.EarthParticle.ATTRACT, 8 + level() / 2);
|
||||||
} else {
|
} else {
|
||||||
guardian.sprite.centerEmitter().burst(MagicMissile.EarthParticle.ATTRACT, 8 + level() / 2);
|
guardian.sprite.centerEmitter().burst(MagicMissile.EarthParticle.ATTRACT, 8 + level() / 2);
|
||||||
guardian.setInfo(curUser, level(), armorToAdd);
|
guardian.setInfo(curUser, level(), armorToAdd);
|
||||||
if (ch != null) guardian.aggro( ch );
|
if (ch.alignment == Char.Alignment.ENEMY || ch.buff(Amok.class) != null) {
|
||||||
|
guardian.aggro(ch);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
Dungeon.level.press(bolt.collisionPos, null, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user