예제 #1
0
 public void Go(string direction)
 {
     if (CurrentRoom.Name == "lockroom" && direction == "east" && !hasKey)
     {
         System.Console.WriteLine("THAT DOOR IS LOCKED YOU NEED THE KEY!");
         return;
     }
     CurrentRoom = CurrentRoom.ChangeRooms(direction);
     System.Console.WriteLine($"{CurrentRoom.Description}");
 }