From UBC Wiki

UBC Snakes

Authors: Yi Yang, Carol Leung

What is the problem?

Make the snake game in Haskell. The objective of the game is to move the snake so that it eats the food generated while not stepping on itself or the wall.

What is the something extra?

Enemy Snakes. They will act the same way as another player and try to eat the food. The player will have to avoid the enemy snake like they would themselves. You can also pick the mode where the other snake tries to eat you instead of the food.

What did we learn from doing this?

How to use Gloss to make game with changing states, taking in user key inputs. Refactoring code to make it more readable. Nerfing the ai snake so that game is not too hard. Generating random number sequences for food locations and for the enemy ai.

Links to code etc