v0.3.2c: added some better saving redundancy to levelgen
This commit is contained in:
parent
71d421fdd0
commit
b4ac28932e
|
@ -230,7 +230,7 @@ public class InterlevelScene extends PixelScene {
|
||||||
}
|
}
|
||||||
GameLog.wipe();
|
GameLog.wipe();
|
||||||
} else {
|
} else {
|
||||||
Dungeon.saveLevel();
|
Dungeon.saveAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
Level level;
|
Level level;
|
||||||
|
@ -246,7 +246,7 @@ public class InterlevelScene extends PixelScene {
|
||||||
private void fall() throws IOException {
|
private void fall() throws IOException {
|
||||||
|
|
||||||
Actor.fixTime();
|
Actor.fixTime();
|
||||||
Dungeon.saveLevel();
|
Dungeon.saveAll();
|
||||||
|
|
||||||
Level level;
|
Level level;
|
||||||
if (Dungeon.depth >= Statistics.deepestFloor) {
|
if (Dungeon.depth >= Statistics.deepestFloor) {
|
||||||
|
@ -260,8 +260,8 @@ public class InterlevelScene extends PixelScene {
|
||||||
|
|
||||||
private void ascend() throws IOException {
|
private void ascend() throws IOException {
|
||||||
Actor.fixTime();
|
Actor.fixTime();
|
||||||
|
|
||||||
Dungeon.saveLevel();
|
Dungeon.saveAll();
|
||||||
Dungeon.depth--;
|
Dungeon.depth--;
|
||||||
Level level = Dungeon.loadLevel( Dungeon.hero.heroClass );
|
Level level = Dungeon.loadLevel( Dungeon.hero.heroClass );
|
||||||
Dungeon.switchLevel( level, level.exit );
|
Dungeon.switchLevel( level, level.exit );
|
||||||
|
@ -270,8 +270,8 @@ public class InterlevelScene extends PixelScene {
|
||||||
private void returnTo() throws IOException {
|
private void returnTo() throws IOException {
|
||||||
|
|
||||||
Actor.fixTime();
|
Actor.fixTime();
|
||||||
|
|
||||||
Dungeon.saveLevel();
|
Dungeon.saveAll();
|
||||||
Dungeon.depth = returnDepth;
|
Dungeon.depth = returnDepth;
|
||||||
Level level = Dungeon.loadLevel( Dungeon.hero.heroClass );
|
Level level = Dungeon.loadLevel( Dungeon.hero.heroClass );
|
||||||
Dungeon.switchLevel( level, Level.resizingNeeded ? level.adjustPos( returnPos ) : returnPos );
|
Dungeon.switchLevel( level, Level.resizingNeeded ? level.adjustPos( returnPos ) : returnPos );
|
||||||
|
|
Loading…
Reference in New Issue
Block a user