From dc7fb9fe08ac9898b31081740c220659e8432e85 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Wed, 4 Sep 2024 12:56:38 -0400 Subject: [PATCH] v2.5.0: fixed cursed wand lightning potentially hitting chars twice --- .../shatteredpixeldungeon/items/wands/CursedWand.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/wands/CursedWand.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/wands/CursedWand.java index 729d68650..083bc899a 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/wands/CursedWand.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/wands/CursedWand.java @@ -559,7 +559,7 @@ public class CursedWand { user.sprite.parent.add(new Lightning(pos - 1 - Dungeon.level.width(), pos + 1 + Dungeon.level.width(), null)); user.sprite.parent.add(new Lightning(pos - 1 + Dungeon.level.width(), pos + 1 - Dungeon.level.width(), null)); for (int i : PathFinder.NEIGHBOURS9){ - if (Actor.findChar(pos+i) != null){ + if (Actor.findChar(pos+i) != null && !affected.contains(Actor.findChar(pos+i))){ affected.add(Actor.findChar(pos+i)); } }