static void Main(string[] args) { MazeGame game = new MazeGame(); var simpleFactory = new MazePrototypeFactory(new Maze(), new Room(), new Door(), new Wall()); var maze = game.CreateGame(simpleFactory); var bombedFactory = new MazePrototypeFactory(new Maze(), new Room(), new Door(), new BombedWall()); var anotherMaze = game.CreateGame(bombedFactory); }
private void CreateGame() { Maze maze; MazeGame game = new MazeGame(); MazePrototypeFactory simpleMazeFactory = new MazePrototypeFactory(new Maze(), new Room(0), new Wall(), new Door()); MazePrototypeFactory bombedMazeFactory = new MazePrototypeFactory(new Maze(), new RoomWithABomb(1), new BombedWall(), new Door()); maze = game.CreateMaze(simpleMazeFactory); }