v2.4.0: transfusion now uses damage wand logic, fixed desc errors too
This commit is contained in:
@@ -29,7 +29,7 @@ import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
|
||||
import com.watabou.noosa.audio.Sample;
|
||||
|
||||
//for wands that directly damage a target
|
||||
//wands with AOE effects count here (e.g. fireblast), but wands with indrect damage do not (e.g. venom, transfusion)
|
||||
//wands with AOE or circumstantial direct damage count here (e.g. fireblast, transfusion), but wands with indirect damage do not (e.g. corrosion)
|
||||
public abstract class DamageWand extends Wand{
|
||||
|
||||
public int min(){
|
||||
|
||||
@@ -50,7 +50,7 @@ import com.watabou.utils.Callback;
|
||||
import com.watabou.utils.PointF;
|
||||
import com.watabou.utils.Random;
|
||||
|
||||
public class WandOfTransfusion extends Wand {
|
||||
public class WandOfTransfusion extends DamageWand {
|
||||
|
||||
{
|
||||
image = ItemSpriteSheet.WAND_TRANSFUSION;
|
||||
@@ -58,6 +58,16 @@ public class WandOfTransfusion extends Wand {
|
||||
collisionProperties = Ballistica.PROJECTILE;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int min(int level) {
|
||||
return 3 + level;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int max(int level) {
|
||||
return 6 + 2*level;
|
||||
}
|
||||
|
||||
private boolean freeCharge = false;
|
||||
|
||||
@Override
|
||||
@@ -124,7 +134,7 @@ public class WandOfTransfusion extends Wand {
|
||||
|
||||
//harms the undead
|
||||
} else {
|
||||
ch.damage(Char.combatRoll(3 + buffedLvl(), 6+2*buffedLvl()), this);
|
||||
ch.damage(damageRoll(), this);
|
||||
ch.sprite.emitter().start(ShadowParticle.UP, 0.05f, 10 + buffedLvl());
|
||||
Sample.INSTANCE.play(Assets.Sounds.BURNING);
|
||||
}
|
||||
@@ -181,9 +191,9 @@ public class WandOfTransfusion extends Wand {
|
||||
public String statsDesc() {
|
||||
int selfDMG = Math.round(Dungeon.hero.HT*0.05f);
|
||||
if (levelKnown)
|
||||
return Messages.get(this, "stats_desc", selfDMG, selfDMG + 3*buffedLvl(), 5+buffedLvl(), 3+buffedLvl()/2, 6+ buffedLvl());
|
||||
return Messages.get(this, "stats_desc", selfDMG, selfDMG + 3*buffedLvl(), 5+buffedLvl(), min(), max());
|
||||
else
|
||||
return Messages.get(this, "stats_desc", selfDMG, selfDMG, 5, 3, 6);
|
||||
return Messages.get(this, "stats_desc", selfDMG, selfDMG, 5, min(0), max(0));
|
||||
}
|
||||
|
||||
private static final String FREECHARGE = "freecharge";
|
||||
|
||||
Reference in New Issue
Block a user