How to Make a Maze Game With Walls in Flash

Updated April 17, 2017

The Adobe Flash program utilises programming technology to create movies or applications. It allows website owners and computer programmers to create interactive websites or place videos on their websites. The Flash Builder section allows programmers to enter code to create games such as the maze game. The maze game requires a player to move his mouse through a maze and reach the end without touching any of the walls. If the walls are touched, the game is over.

Open Adobe Flash. Create a new Flash File (ActionScript 2.0).

Select the drawing tool and create the title for your maze.

Press "F9" and type in "stop();" to keep the page from continuing on to the next frame, as a movie does.

Select the box tool and create a starting box. Colour the box your preferred colour.

Select the box and press "F8." Make the box a button. Then type in the following code:





Press "F7" and select the second frame in the timeline. On this frame, use the drawing tool to draw your maze.

Select the entire maze and convert it to a button from the "F8" menu.

Press "F9" to open the actionscript box. Type in the following code:





Draw the destination at the end of the maze. This is the place where players will attempt to take their mouse. It can be any shape you choose.

Press "F8" and convert the destination to a button. Type in:





Press "F7" to create the third frame. Go to this frame and use the drawing tool to create the winners page.

Press "F7" and go to the fourth frame. Draw the losers page.

Create a box on the fourth frame. Place text inside the box that says "Play Again?" Press "F8" to make this a button.

Type in this code to make the game return to the maze so the player can try again:






To create this game, you must have the Adobe Flash program, not the Adobe Flash Player. The Adobe Flash Player only allows you to view pages created by the Adobe Flash program, not create them. When drawing the maze pattern on your second frame, keep clear the area on the first page where the stop button is located so that players do not automatically lose because their mouse is on a wall.

Things You'll Need

  • Adobe Flash program
Cite this Article A tool to create a citation to reference this article Cite this Article

About the Author

Based in Laramie, Wyo., Joanna Swanson has been writing in her professional life since 2004. She currently writes for various websites and enjoys reading a wide variety of books. Swanson holds a bachelor's degree in business administration from the University of Wyoming.