-
Give your game a name via an HTML element ex: (
) -
Add a game surface ("canvas") for your snake to spread ex:()
-
Give your snake some styling. Locate the spot in the index.html file where the "insert the style sheet" is and add in the following
-
Below the div containing the canvas, draft the instructions on how to play your game
-
Insert the script which controls your snake. Locate the spot in the index.html file where the "insert the javascript" is and add in the following
-
Add a instructions for the user on how to start the game. (Hint - Line 23)
-
Keys Find the variable 'keys' on line 165, this is what helps control your snake. Utilizing the website http://keycode.info/ insert the key that will start your game in the start_game array. (ex: start_game: [13, 32])
-
Repeat the same concept in step 7, but for the arrays left, right, up, down.