How to Play: • Arrow keys to move • Eat apples (the red tiles) to grow • Don't bump into yourself or the edge.
There wasn't a lot of effort put into this project. This project was mostly a test to see if I can make something snake-like. Known Bugs: • Rapid movement if different arrow keys are spammed (for example, up-left-up-left). This is because the snake moves every time a valid arrow key is pressed, to make it so that rapid U-turns are possible. I decided not to fix this bug because doing so would cause more harm than good. • It is possible to die of collision when your snake is just 4 tiles long. This happens because the tail updates its position last, which will result in the head colliding with the tail for a moment if you make the snake go into a 2-by-2 square. • The speed of the snake changes for a moment after you press a valid arrow key. This happens because of something I call the cooldown system. The cooldown system makes sure that auto-moving does not happen directly after a direction change, which would result in the snake suddenly moving forwards 2 tiles instead of one. It accomplishes that by creating a cooldown for auto-moving after a valid arrow key press. This means that if timed correctly, a valid arrow key press can slow the snake for a moment.