First version of laser
This commit is contained in:
@@ -10,18 +10,19 @@ const legend = {
|
||||
wall: 6,
|
||||
demiWall: 7,
|
||||
target: 8,
|
||||
ligthLaser: 9,
|
||||
}
|
||||
|
||||
// Grid test
|
||||
|
||||
let grid = [
|
||||
[0, 0, 0, 0, 0, 0, 0, 0],
|
||||
[0, 1, 0, 0, 0, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 8, 0],
|
||||
[0, 0, 3, 0, 0, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 8, 0],
|
||||
[1, 9, 9, 9, 9, 9, 3, 0],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0],
|
||||
]
|
||||
|
||||
@@ -67,6 +68,9 @@ function loadGrid () {
|
||||
case legend.target:
|
||||
cell.classList.add("target");
|
||||
break;
|
||||
case legend.ligthLaser:
|
||||
cell.classList.add("light-laser");
|
||||
break;
|
||||
}
|
||||
|
||||
lign.appendChild(cell);
|
||||
|
||||
Reference in New Issue
Block a user