/The_Labyrinth

A maze game based on the Greek Labyrinth. Can you escape the Labyrinth?

Primary LanguageJava

The_Labyrinth

A maze game based on the Greek Labyrinth. Can you escape the Labyrinth?

Description

This game features a dark maze with a key gaurded by a minotaur in the center of the maze. The player starts at the exit, so all they must do is go to the center, steal the key, and exit the maze while avoiding the minotaur. An interesting feature in this game is that the visible area to the player is only the ray in front of the player, and the view may be blocked by walls or obstacles. The main menu screen is shown below:

The instructions for the game are shown if the user clicks on "Help", as shown below:

An example of gameplay is shown below:

Maze Generation Algorithm

The maze was created using a randomized version of Prim's Algorithm, the same one as used in my Empty Life Project (https://github.com/dipeshmanandhar/Empty_Life).

2D Visibility Algorithm

The visible area of the player was created by superimposing a ray (cone) on top of the shape created by a Raycasting algorithm that sends vectors to all nearby wall's corners. This algorithm was optimized through many ways, including only looking at nearby maze cells and parallizing most of the work onto multiple threads.

This project was completed by May 2018