v0.8.0: fixed rare crash errors with spinners and blast wave effects
This commit is contained in:
parent
b23a091ed6
commit
d726efb948
|
@ -158,7 +158,12 @@ public class Spinner extends Mob {
|
|||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//in case target is at the edge of the map and there are no more cells in the path
|
||||
if (b.path.size() <= collisionIndex){
|
||||
return -1;
|
||||
}
|
||||
|
||||
int webPos = b.path.get( collisionIndex+1 );
|
||||
|
||||
if (Dungeon.level.passable[webPos]){
|
||||
|
|
|
@ -135,6 +135,8 @@ public class WandOfBlastWave extends DamageWand {
|
|||
collided = true;
|
||||
}
|
||||
|
||||
if (dist < 0) return;
|
||||
|
||||
final int newPos = trajectory.path.get(dist);
|
||||
|
||||
if (newPos == ch.pos) return;
|
||||
|
|
Loading…
Reference in New Issue
Block a user