From fcec39ea965db6145c627c07926c8329ec79e4c9 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Tue, 23 Feb 2021 20:06:19 -0500 Subject: [PATCH] v0.9.2: fixed regrowth bombs checking the incorrect terrain --- .../shatteredpixeldungeon/items/bombs/RegrowthBomb.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/RegrowthBomb.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/RegrowthBomb.java index 6ab86b1a4..bdb7f2bc4 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/RegrowthBomb.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/RegrowthBomb.java @@ -66,7 +66,7 @@ public class RegrowthBomb extends Bomb { for (int i = 0; i < PathFinder.distance.length; i++) { if (PathFinder.distance[i] < Integer.MAX_VALUE) { Char ch = Actor.findChar(i); - int t = Dungeon.level.map[cell]; + int t = Dungeon.level.map[i]; if (ch != null){ if (ch.alignment == Dungeon.hero.alignment) { //same as a healing potion @@ -75,7 +75,7 @@ public class RegrowthBomb extends Bomb { } } else if ((t == Terrain.EMPTY || t == Terrain.EMPTY_DECO || t == Terrain.EMBERS || t == Terrain.GRASS || t == Terrain.FURROWED_GRASS || t == Terrain.HIGH_GRASS) - && Dungeon.level.plants.get(cell) == null){ + && Dungeon.level.plants.get(i) == null){ plantCandidates.add(i); } GameScene.add( Blob.seed( i, 10, Regrowth.class ) );