Doors #156
@@ -26,8 +26,8 @@ class TestBroguelike(unittest.TestCase):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    def is_connex(self, grid: List[List[Tile]]) -> bool:
 | 
					    def is_connex(self, grid: List[List[Tile]]) -> bool:
 | 
				
			||||||
        h, w = len(grid), len(grid[0])
 | 
					        h, w = len(grid), len(grid[0])
 | 
				
			||||||
        y, x = randint(0, h - 1), randint(0, w - 1)
 | 
					        y, x = -1, -1
 | 
				
			||||||
        while not (grid[y][x].can_walk() or grid[y][x] == Tile.DOOR):
 | 
					        while not grid[y][x].can_walk():
 | 
				
			||||||
            y, x = randint(0, h - 1), randint(0, w - 1)
 | 
					            y, x = randint(0, h - 1), randint(0, w - 1)
 | 
				
			||||||
        queue = Map.neighbourhood(grid, y, x)
 | 
					        queue = Map.neighbourhood(grid, y, x)
 | 
				
			||||||
        while queue:
 | 
					        while queue:
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user