Hex Snake

Snake, except played on a hexagonal grid.

The game is played on a 10 by 10 hexagonal grid, at any given point one hex on the board would contain a goal. The player would control a snake which would move at a fixed rate facing forward by changing its heading using the arrow keys. Each time the snake head reaches the goal it would grow by one hex. The game would end when the snake head collides with the board boundary or itself. The player score would be determined by the length of the snake at game end.

Gameplay

Start: At the start of the game the snake would be placed at the center of the board facing a random direction. The goal hex would be randomly generated at any hex other than ones occupied by the snake.

(Note): additional obstacles may also be generated and placed in random hexes which are not occupied by the snake or the goal.

Movement: The game runs at a fixed but configurable timestep. At each timestep the snake would move to an adjacent hex whose direction is determined by the current heading of the snake head. If the snake occupies more than one hex, each subsequent snake body would move to occupy the hex of its predecessor.

When the player presses the left or right arrow key, the snake head's heading would rotate counter-clockwise or clockwise by one hexagonal side respectively.

Goal: When the snake head reaches the goal hex, a new goal hex is immediately randomly generated in another tile not occupied by the snake or optional obstacles. Additionally, the snake would occupy one more hex by appending one more snake body at the end of the snake in any direction as long as it does not violate board boundaries or obstacles.

End: The game ends whenever the snake head would, in the next timestep, occupy a board boundary, board obstacle, or hex currently occupied by the snake body.

Player score is then calculayed by the length of the snake body.

Board: The board hexagonal grid shall be arranged by pointy topped fashion. Top down 2D view shall be used and all displayed objects shall be flat.

Assets

Game style shall be abstract and flat geometric shapes so no assets should be necessary.