Code Monkey home page Code Monkey logo

cuebitts.github.io's Introduction

dot grid exists To start I used JS to create 25 dots. I then styled them with CSS Grid to organize them into a grid.

vertical grid lines exist I used a similar process to make the vertical lines of the grid. They will have to be seperate elements to check if they have been clicked.

horizontal grid lines exist Same process as that for adding the vertical grid lines.

can click to add line I used the loops to add event listeners that when clicked change the color of the line from gray to red.

can hover to preview line I used event listeners again that when hovered over change the color of the line from gray to light gray.

lines are added in better order for array I changed the way the lines were added to nested for loops that will correspond to its location in the array.

function that can check if a box is surrounded exists I made my pseudo-code into a real function as well as tweaking the initial grid loop so a the grid can be checked for closed boxes.

lines will now alternate color and boxes will fill in with the color that closed them I added the gameplay loop and did some debugging to tie together most of the game's functions.

points are counted and player is granted an extra turn for earning one I added conditions to tell if a box was filled and by whom to grant players who earn points an extra turn and tally up the winner.

cuebitts.github.io's People

Stargazers

Quinlan Hogan avatar

Watchers

Quinlan Hogan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.