Maze Game

  scripts
  sprites
See inside
Instructions

USE TURBO MODE!!!! (Shift + click the green flag)

You are the BLUE dot, your goal is the RED dot. MOVE using the ARROW KEYS.

TO MAKE IT HARDER, click settings, and turn 'trail' off - the character will no longer leave any trail.

@chooper100

Notes and Credits

Please don't post your scores! Each maze is different and therefore times / moves can not be compared.

UPDATED - Much faster maze generation algorithm :)

Maze generation algorithm:
Uses the Depth First Search algorithm, based on the description here:
https://en.wikipedia.org/wiki/Maze_generation_algorithm#Depth-first_search

How it works:
Effectively, we start at the top left, and then for every cell (space), we check if there are any neighboring cells that haven't been filled yet. If there are, we choose one of them at random and connect it to the cell. If there aren't any, we presume we have found a dead end and we backtrack until we find any available spaces. This ensures that all spaces are filled.

The end point is chosen at random from a list of dead ends that was recorded whilst generating the maze. The start point is always in the top-left, although theoretically it could be anywhere. (See the 'set [#Start X v] to [0]' and 'set [#Start Y v] to [0]' blocks in the 'generate maze' custom block.)

Also, as we want to complete the maze online, we have to all the directions the player can move in at any point. Therefore, whilst we generate the maze, we also use a list called '#Maze Data', which assigns 1 nibble (4 1s or 0s) to each point. Each character position represents a different direction. A 1 indicates that you can't move that way, and a 0 indicates that you can.

Credits:
freesfx.co.uk -> Wall hit sound
pond5.com -> Level complete sound
yookamusic.com -> Music

Bebas Neue -> Font

Final note:
Apologies to everyone who was offended by my use of the orange variable displays. The project was kinda rushed and clone text engines are awkward to use when you already have thousands of clones :P

Shared: 13 Jan 2016 Modified: 21 Jan 2016
Favorite this project 105
Love this project 133
Total views 2584
View the remix tree  5
  
More projects by chooper100