top of page

Snake Game

Project name: Snake
Made in: Summer vacation 2021.

GitHub:

github.png

Team size: 1

Tools used: Unity, visual studio (2019)  C#, GitHub.
 

Description:

This is my second successful project witch I made all on my own and works perfectly, the project is also playable on itch.io, I made this project as a follow up from pong, because I liked working on some old classic games to get an basic feeling in programming and slowly learning more. Personally I loved working on this classic game.

Schermopname (489)_edited.jpg

Code snippets

Screenshot (9)_edited.jpg

Snake script:

In this script I made the snake's movement code very simple code indeed, but it was my first attempt in a 2D game world to make a fully controllable character. The snake can move up, down, left and right using vector2 directions and key inputs.

Snake's food script:

In this script I made the food for the snake, by eating the food the snake/player will grow bigger. This way it's harder to move around the map without eating yourself. The food will respawn to a new random position on the map, every time it get's eaten.

Screenshot (8)_edited.jpg
bottom of page