v1.3.0: fixed inter floor teleporting working on locked floors
This commit is contained in:
@@ -386,7 +386,7 @@ public class Dungeon {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static boolean interfloorTeleportAllowed(){
|
public static boolean interfloorTeleportAllowed(){
|
||||||
if (Dungeon.hero != null && Dungeon.hero.belongings.getItem(Amulet.class) != null){
|
if (Dungeon.level.locked || (Dungeon.hero != null && Dungeon.hero.belongings.getItem(Amulet.class) != null)){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
@@ -722,11 +722,11 @@ public class Dungeon {
|
|||||||
|
|
||||||
Dungeon.level = null;
|
Dungeon.level = null;
|
||||||
Actor.clear();
|
Actor.clear();
|
||||||
|
|
||||||
Bundle bundle = FileUtils.bundleFromFile( GamesInProgress.depthFile( save, depth, branch ));
|
Bundle bundle = FileUtils.bundleFromFile( GamesInProgress.depthFile( save, depth, branch ));
|
||||||
|
|
||||||
Level level = (Level)bundle.get( LEVEL );
|
Level level = (Level)bundle.get( LEVEL );
|
||||||
|
|
||||||
if (level == null){
|
if (level == null){
|
||||||
throw new IOException();
|
throw new IOException();
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user