Memory Game is a Light & Sound Memory game to apply for CodePath's SITE Program.
Submitted by: John Tse
Time spent: 4 hours spent in total
Link to project: (https://glitch.com/edit/#!/vigorous-stealth-goldenrod?path=script.js%3A1%3A0)
The following required functionality is complete:
- Game interface has a heading (h1 tag), a line of body text (p tag), and four buttons that match the demo app
- "Start" button toggles between "Start" and "Stop" when clicked.
- Game buttons each light up and play a sound when clicked.
- Computer plays back sequence of clues including sound and visual cue for each button
- Play progresses to the next turn (the user gets the next step in the pattern) after a correct guess.
- User wins the game after guessing a complete pattern
- User loses the game after an incorrect guess
The following optional features are implemented:
- Any HTML page elements (including game buttons) has been styled differently than in the tutorial
- Buttons use a pitch (frequency) other than the ones in the tutorial
- More than 4 functional game buttons
- Playback speeds up on each turn
- Computer picks a different pattern each time the game is played
- Player only loses after 3 mistakes (instead of on the first mistake)
- Game button appearance change goes beyond color (e.g. add an image)
- Game button sound is more complex than a single tone (e.g. an audio file, a chord, a sequence of multiple tones)
- User has a limited amount of time to enter their guess on each turn
The following additional features are implemented:
- List anything else that you can get done to improve the app!
- I can make a timer for the game lol
Here's a walkthrough of implemented user stories:
-
If you used any outside resources to help complete your submission (websites, books, people, etc) list them here. w3schools.com
-
What was a challenge you encountered in creating this submission (be specific)? How did you overcome it? (recommended 200 - 400 words) One of the challenges I encountered was learning the syntax of HTML and CSS. Although I previously took HTML in high school, I never fine tuned my skills or pushed what I could do in order to truly showcase my skills in the languages. After learning Java and C++ for backend programming, it was a bit slow transition to get used to the syntax of HTML and CSS, as Java and C++ are much more strict on declarations. Another struggle I encountered was fine tuning the sounds of the buttons. At certain speeds of the game, sometimes the sound would not be heard. I overcame this by setting the frequencies to a certain range, therefore making it much easier to hear. The final challenge I encountered while creating this submission was using the variables provided. Although the variables were given by the tutorial, I had a little struggle when trying to refernece the variables in my personally created functions. This was overcome by checking the top of the jss page.
-
What questions about web development do you have after completing your submission? (recommended 100 - 300 words) Are there any ways to communicate with a database? What other ways would have made the code much more efficient, such as recursive calls? Are there better ways to spruce up and modify my webpage to make it look more friendly and interactive?
-
If you had a few more hours to work on this project, what would you spend them doing (for example: refactoring certain functions, adding additional features, etc). Be specific. (recommended 100 - 300 words) If I had more time to work on this project, I would try and implement different sounds for the buttons. Although I have changed the frequencies of the sounds in the map, I would ultimately wish to create a game where the sounds played are the laughs of the characters from Family Guy characters. I also would like to imeplment a real working timer. I have previously tried to imeplement the timer but to no succcess. In addition to this, I hope to create a leaderboard or keep track of the scores. By doing this, I would be able to log and comapre other users speeds and times it took per attempt, keeping track to see if the speed of the person completed is faster than the average of everyone else. I would also like to include a link to a video tutorial of how the game is played into the game.
Copyright [JOHN TSE]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at