v1.0.3: fixed rare crashes when bundling tengu fire ability

This commit is contained in:
Evan Debenham 2021-08-30 19:11:21 -04:00
parent 3e73344ab8
commit 72e0b6ee1c

View File

@ -799,14 +799,14 @@ public class Tengu extends Mob {
public void storeInBundle(Bundle bundle) { public void storeInBundle(Bundle bundle) {
super.storeInBundle(bundle); super.storeInBundle(bundle);
bundle.put( DIRECTION, direction ); bundle.put( DIRECTION, direction );
bundle.put( CUR_CELLS, curCells ); if (curCells != null) bundle.put( CUR_CELLS, curCells );
} }
@Override @Override
public void restoreFromBundle(Bundle bundle) { public void restoreFromBundle(Bundle bundle) {
super.restoreFromBundle(bundle); super.restoreFromBundle(bundle);
direction = bundle.getInt( DIRECTION ); direction = bundle.getInt( DIRECTION );
curCells = bundle.getIntArray( CUR_CELLS ); if (bundle.contains( CUR_CELLS )) curCells = bundle.getIntArray( CUR_CELLS );
} }
public static class FireBlob extends Blob { public static class FireBlob extends Blob {