v0.3.2c: re-added bones to prison boss level

This commit is contained in:
Evan Debenham 2015-11-18 17:10:19 -05:00 committed by Evan Debenham
parent ba0044f48b
commit d7ae88d963

View File

@ -21,6 +21,7 @@
package com.shatteredpixel.shatteredpixeldungeon.levels; package com.shatteredpixel.shatteredpixeldungeon.levels;
import com.shatteredpixel.shatteredpixeldungeon.Assets; import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.shatteredpixel.shatteredpixeldungeon.Bones;
import com.shatteredpixel.shatteredpixeldungeon.Dungeon; import com.shatteredpixel.shatteredpixeldungeon.Dungeon;
import com.shatteredpixel.shatteredpixeldungeon.ShatteredPixelDungeon; import com.shatteredpixel.shatteredpixeldungeon.ShatteredPixelDungeon;
import com.shatteredpixel.shatteredpixeldungeon.actors.Actor; import com.shatteredpixel.shatteredpixeldungeon.actors.Actor;
@ -81,7 +82,7 @@ public class PrisonBossLevel extends Level {
@Override @Override
public void storeInBundle( Bundle bundle ) { public void storeInBundle( Bundle bundle ) {
super.storeInBundle(bundle); super.storeInBundle(bundle);
bundle.put(STATE, state); bundle.put( STATE, state );
bundle.put( TENGU, tengu ); bundle.put( TENGU, tengu );
bundle.put( STORED_ITEMS, storedItems); bundle.put( STORED_ITEMS, storedItems);
} }
@ -142,6 +143,10 @@ public class PrisonBossLevel extends Level {
@Override @Override
protected void createItems() { protected void createItems() {
Item item = Bones.get();
if (item != null) {
drop( item, randomRespawnCell() ).type = Heap.Type.REMAINS;
}
drop(new IronKey(10), randomPrisonCell()); drop(new IronKey(10), randomPrisonCell());
} }
@ -178,15 +183,9 @@ public class PrisonBossLevel extends Level {
} }
} }
@Override
public Heap drop( Item item, int cell ) {
return super.drop( item, cell );
}
@Override @Override
public int randomRespawnCell() { public int randomRespawnCell() {
return 5+3*32; return 5+2*32 + NEIGHBOURS8[Random.Int(8)]; //random cell adjacent to the entrance.
} }
@Override @Override