diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/WeakFloorRoom.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/WeakFloorRoom.java index b563b4381..3a7f55c5d 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/WeakFloorRoom.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/WeakFloorRoom.java @@ -41,34 +41,30 @@ public class WeakFloorRoom extends SpecialRoom { Door door = entrance(); door.set( Door.Type.REGULAR ); - if (door.x == left) { - for (int i=top + 1; i < bottom; i++) { - Painter.drawInside( level, this, new Point( left, i ), Random.IntRange( 1, width() - 3 ), Terrain.EMPTY_SP ); - } - } else if (door.x == right) { - for (int i=top + 1; i < bottom; i++) { - Painter.drawInside( level, this, new Point( right, i ), Random.IntRange( 1, width() - 3 ), Terrain.EMPTY_SP ); - } - } else if (door.y == top) { - for (int i=left + 1; i < right; i++) { - Painter.drawInside( level, this, new Point( i, top ), Random.IntRange( 1, height() - 3 ), Terrain.EMPTY_SP ); - } - } else if (door.y == bottom) { - for (int i=left + 1; i < right; i++) { - Painter.drawInside( level, this, new Point( i, bottom ), Random.IntRange( 1, height() - 3 ), Terrain.EMPTY_SP ); - } - } - Point well = null; + if (door.x == left) { + for (int i=top + 1; i < bottom; i++) { + Painter.drawInside( level, this, new Point( left, i ), Random.IntRange( 1, width() - 4 ), Terrain.EMPTY_SP ); + } well = new Point( right-1, Random.Int( 2 ) == 0 ? top + 2 : bottom - 1 ); } else if (door.x == right) { + for (int i=top + 1; i < bottom; i++) { + Painter.drawInside( level, this, new Point( right, i ), Random.IntRange( 1, width() - 4 ), Terrain.EMPTY_SP ); + } well = new Point( left+1, Random.Int( 2 ) == 0 ? top + 2 : bottom - 1 ); } else if (door.y == top) { + for (int i=left + 1; i < right; i++) { + Painter.drawInside( level, this, new Point( i, top ), Random.IntRange( 1, height() - 4 ), Terrain.EMPTY_SP ); + } well = new Point( Random.Int( 2 ) == 0 ? left + 1 : right - 1, bottom-1 ); } else if (door.y == bottom) { + for (int i=left + 1; i < right; i++) { + Painter.drawInside( level, this, new Point( i, bottom ), Random.IntRange( 1, height() - 4 ), Terrain.EMPTY_SP ); + } well = new Point( Random.Int( 2 ) == 0 ? left + 1 : right - 1, top+2 ); } + Painter.set(level, well, Terrain.CHASM); CustomTiledVisual vis = new HiddenWell(); vis.pos(well.x, well.y);