previous

page 27

next
new line in index.html in game section:
<script src='panel.js'></script>
new for styles.css
#panel {
grid-row: 2 / span 1;
grid-column: 2 / span 5;
display:flex;
justify-content: space-evenly;
align-items: center;
opacity:.6;
}
.cell {
width:5vmin;
height:5vmin;
border:3px groove;
}
making the panel work

First remove the onClick attribute from the rock in your index.html.
Then add this cell_clicked function to your clicks.js:

function cell_clicked(image) {
if (image.id==g_colours[g_kount]) {
Hide(image.id);
g_kount++;
if (g_kount==7) open_rock();
} else {
Show_class('cell'); g_kount=0;
}
}

Still more to do ... see the next page.

previous
next