Extra Room

#Initialise
#set up dictionaries
MAP = {
    ##### modified foyer forward movement to kitchen
    'foyer_forward':'kitchen',
       'foyer_right':'lounge',
        'foyer_backward':'front door',
       'foyer_left':'bedroom',
        'bedroom_right':'foyer',      
        'front door_forward':'foyer',
    ##### Added movements in and out of the kitchen
       'kitchen_backward':'foyer',
       'kitchen_forward':'back door',
    ##### Added lounge left because that is no longer the end of the game
       'lounge_left': 'foyer'
       }
 
DESC = {'foyer':'You are in the foyer. It is dark and scary. You want to get out! ',
         'back door':'Congratulations, you have escaped via the back door! ',
         'bedroom':'You are in the bedroom.',
         'lounge':'You are in the lounge.',
         'front door':'The front door is locked!',
        ##### A New room Added: Kitchen
         'kitchen':'You are in the kitchen'
        }
 
#set up list of items that end the game
##### Removed lounge from FINISH and added back door
FINISH = ['back door','quit','dead','end' ]
 
 
#starting location
room = 'foyer'
 
#Start of game code
name = input('What is your name? ')
print ('Hello',name)
print ('You are in a castle with many rooms. ')
print ('Your challenge is to escape the castle.')
 
#loops continuously until a break. Note capital letter in boolean value True
while True:
    print (DESC[room])
 
         
    if room in FINISH:
        break
    direction = input( 'Enter a direction? Choose from forward, backward, left, right or quit ')
    if direction in FINISH:
        break
    key = room + '_' + direction
     
    if key in MAP:
        room = MAP[key]
    else :
        print ('You can\'t go ' +direction+'. ' )
print ('Game over!')