v0.4.2: fixed two crash bugs caused by recent changes

This commit is contained in:
Evan Debenham 2016-08-25 10:49:52 -04:00 committed by Evan Debenham
parent a29c274484
commit 1461003683
2 changed files with 2 additions and 1 deletions

View File

@ -78,6 +78,7 @@ public class Tilemap extends Visual {
bufferPositions = new short[size];
for (int i = 0; i < bufferPositions.length; i++)
bufferPositions[i] = -1;
bufferLength = 0;
width = cellW * mapWidth;
height = cellH * mapHeight;

View File

@ -259,7 +259,7 @@ public class Wandmaker extends NPC {
if (setRoom( rooms )){
Wandmaker npc = new Wandmaker();
do {
npc.pos = Dungeon.level.pointToCell(room.random());
npc.pos = level.pointToCell(room.random());
} while (level.map[npc.pos] == Terrain.ENTRANCE || level.map[npc.pos] == Terrain.SIGN);
level.mobs.add( npc );