v3.0.0: fixed grass blocking icecap and removed unnecessary pathfind
This commit is contained in:
@@ -29,7 +29,6 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.FrostImbue;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.HeroSubClass;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
|
||||
import com.watabou.utils.BArray;
|
||||
import com.watabou.utils.PathFinder;
|
||||
|
||||
public class Icecap extends Plant {
|
||||
@@ -45,12 +44,10 @@ public class Icecap extends Plant {
|
||||
if (ch instanceof Hero && ((Hero) ch).subClass == HeroSubClass.WARDEN){
|
||||
Buff.affect(ch, FrostImbue.class, FrostImbue.DURATION*0.3f);
|
||||
}
|
||||
|
||||
PathFinder.buildDistanceMap( pos, BArray.not( Dungeon.level.losBlocking, null ), 1 );
|
||||
|
||||
for (int i=0; i < PathFinder.distance.length; i++) {
|
||||
if (PathFinder.distance[i] < Integer.MAX_VALUE) {
|
||||
Freezing.affect( i );
|
||||
for (int i : PathFinder.NEIGHBOURS9){
|
||||
if (!Dungeon.level.solid[pos+i]) {
|
||||
Freezing.affect( pos+i );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user