Skip to content

Commit 10be00c

Browse files
committed
Section 22: Iterating Over Walls
1 parent f03a516 commit 10be00c

2 files changed

Lines changed: 15 additions & 3 deletions

File tree

22-Javascript-with-the-Canvas-API/02-Maze copy/index.js

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,16 @@ const stepThroughCell = (row, column) => {
118118
stepThroughCell(startRow, startColumn)
119119
// stepThroughCell(1, 1)
120120
// console.log(grid)
121-
console.log(verticals);
122-
console.log(horizontals);
121+
// console.log(verticals);
122+
// console.log(horizontals);
123123

124+
125+
horizontals.forEach((row) => {
126+
row.forEach((open) => {
127+
if(open === true) {
128+
return
129+
}
130+
131+
const wall = Bodies.rectangle()
132+
})
133+
})

22-Javascript-with-the-Canvas-API/README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,4 +71,6 @@ console.log(grid)
7171

7272
## 16. 20 Updating Horizontal Wall Values
7373

74-
## 17. 21 Validating Wall Structure
74+
## 17. 21 Validating Wall Structure
75+
76+
## 18. 22 Iterating Over Walls

0 commit comments

Comments
 (0)