v0.6.1: small tweak to wand of fireblast logic

This commit is contained in:
Evan Debenham 2017-07-03 23:19:00 -04:00
parent b31fc10136
commit 3f587ffc47
2 changed files with 12 additions and 3 deletions

View File

@ -3,7 +3,7 @@ buildscript {
jcenter() jcenter()
} }
dependencies { dependencies {
classpath 'com.android.tools.build:gradle:2.3.2' classpath 'com.android.tools.build:gradle:2.3.3'
} }
} }

View File

@ -74,8 +74,17 @@ public class WandOfFireblast extends DamageWand {
for( int cell : affectedCells){ for( int cell : affectedCells){
if (Level.flamable[cell] || !Dungeon.level.adjacent(bolt.sourcePos, cell)) //ignore caster cell
if (cell == bolt.sourcePos){
continue;
}
//only ignite cells directly near caster if they are flammable
if (!Dungeon.level.adjacent(bolt.sourcePos, cell)
|| Level.flamable[cell]){
GameScene.add( Blob.seed( cell, 1+chargesPerCast(), Fire.class ) ); GameScene.add( Blob.seed( cell, 1+chargesPerCast(), Fire.class ) );
}
Char ch = Actor.findChar( cell ); Char ch = Actor.findChar( cell );
if (ch != null) { if (ch != null) {