/******************************************************************** File: maze.cc Author: Dana Vrajitoru Description: The class handling the maze. Project: A sprite moving through a maze application. Last updated: February 10, 2011. ********************************************************************/ #include #include #include "bus.h" #include "maze.h" // Default constructor. Should initialize the table. Maze::Maze() { int i, j; static int tab[mazew][mazeh] = {{1, 1, 1, 1, 1, 1, 1, 1, 1, 1}, {1, 0, 0, 0, 0, 0, 1, 0, 0, 1}, {1, 1, 0, 1, 1, 0, 1, 0, 1, 1}, {1, 0, 0, 0, 1, 0, 0, 0, 0, 1}, {1, 0, 1, 1, 1, 0, 1, 1, 1, 1}, {1, 0, 1, 0, 1, 0, 0, 0, 1, 1}, {1, 0, 0, 0, 0, 0, 1, 0, 0, 1}, {1, 1, 1, 0, 1, 0, 1, 0, 1, 1}, {1, 0, 0, 0, 1, 0, 0, 0, 0, 1}, {1, 1, 1, 1, 1, 1, 1, 1, 1, 1}}; for (i=0; i