v1.4.1: fixed rare cases of being able to self-target with cursed wands

This commit is contained in:
Evan Debenham
2022-10-05 13:03:24 -04:00
parent 3d66ee5e86
commit 4514995e9b
2 changed files with 4 additions and 3 deletions
@@ -548,7 +548,8 @@ public abstract class Wand extends Item {
} }
public int collisionProperties(int target){ public int collisionProperties(int target){
return collisionProperties; if (cursed) return Ballistica.MAGIC_BOLT;
else return collisionProperties;
} }
public static class PlaceHolder extends Wand { public static class PlaceHolder extends Wand {
@@ -60,8 +60,8 @@ public class WandOfWarding extends Wand {
@Override @Override
public int collisionProperties(int target) { public int collisionProperties(int target) {
if (Dungeon.level.heroFOV[target]) return Ballistica.STOP_TARGET; if (cursed || !Dungeon.level.heroFOV[target]) return Ballistica.PROJECTILE;
else return Ballistica.PROJECTILE; else return Ballistica.STOP_TARGET;
} }
private boolean wardAvailable = true; private boolean wardAvailable = true;