src/scripts/Dungeon.js
//enters the dungeon; also does some checks to verify that dungeon was properly setup
enters the dungeon; also does some checks to verify that dungeon was properly setup
enters the dungeon ; also does some checks to verify that dungeon was properly setup
enterDungeon() {
        this.actualRoom = null;
        var Entry = null;
        var Exit = null;
        var Room;
        var rooms = (this.floors[0]).allRooms();
        for (var i = 0; i < rooms.length; i++ ) {
            Room = (rooms[i]);
            if (Room.isDungeonEntry) {
                Entry = Room;
            }
            if (Room.isDungeonExit) {
                Exit = Room;
            }
        }
        if (Entry == null || Exit == null) {
            throw new Error('Error: Dungeon-Exit or Entry missing');
        }
        this.floorChange(Entry.floor,Entry.floor);
        this.moveToRoom(Entry);
    }
enterDungeon ( ) { this . actualRoom = null ; var Entry = null ; var Exit = null ; var Room ; var rooms = ( this . floors [ 0 ] ) . allRooms ( ) ; for ( var i = 0 ; i < rooms . length ; i ++ ) { Room = ( rooms [ i ] ) ; if ( Room . isDungeonEntry ) { Entry = Room ; } if ( Room . isDungeonExit ) { Exit = Room ; } } if ( Entry == null || Exit == null ) { throw new Error ( 'Error: Dungeon-Exit or Entry missing' ) ; } this . floorChange ( Entry . floor , Entry . floor ) ; this . moveToRoom ( Entry ) ; }
enters the dungeon; also does some checks to verify that dungeon was properly setup
enters the dungeon ; also does some checks to verify that dungeon was properly setup
//this.Mapper = new DngMapper(); //this.resumeRoom=this.resumeRoomMenu; //search the dungeon-Entry, has to be in first floor // playerMenu();