1 / 25

THE 3D MAZE

THE 3D MAZE. Recursive backtracking maze generator. By::: Nishan Pantha(528 ) Navin Ayer(526 ) Pusparaj Bhattarai(532 ). Objectives.

jacie
Download Presentation

THE 3D MAZE

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. THE 3D MAZE Recursive backtracking maze generator By::: Nishan Pantha(528) Navin Ayer(526) Pusparaj Bhattarai(532)

  2. Objectives 1. To learn Object Oriented Programming in C++.2. To use built-in features and functions of C++ in a simple manner.3. To learn about the graphical programming using OpenGL.4. To learn file streaming (create, write, save and read files).5. To model the real world in programing using OOP.6. To use 3D graphics to make the program look real and user friendly as possible.7. To use the external library and utility…1. Opengl (Open Graphic Library)2. GLUT (or freeglut)3. SOIL (Simple Opengl Image Library )4. SDL

  3. Introduction 1. Random Maze Generator using Recursive Backtracking Algorithm .2. 3D maze simulation .3. Game is efficient i.e. runs using less memory and processing .

  4. Existing System 1. Inspired from the algorithm of maze solver and maze generator.2. There are several flash game… from which some are Random maze generator . Till now there are no famous maze game as far our knowledge.

  5. Methodology 1. The game is designed by employing Object Oriented Approach of C++ .2. 3D graphics is done through OpenGL and freeglut(utility) .3. Window and key events through OpenGL and freeglut .4. Texture loading through SDL / SOIL .

  6. Application 1. For the gaming lover and puzzle solver……2. For any age group….since it does not contain any violence or scary scene ….3. For people who likes random level than the same one.4. 3D gaming instead of 2D gaming experience . 5 .Complex algorithm into simple programmable code .

  7. Lets take this maze for the description of the algorithm i.e. Recursive Backtracking Maze Generator

  8. The real maze looks like this after intialization.

  9. Initial position(which is floor)

  10. Closed(i.e surrounded by wall) Closed(i.e surrounded by wall) No permission to visited the surrounding wall of the whole maze (since they are not surrounded by walls )

  11. Now this place becomes the floor i.e. the path between initial and final for this case…. Closed(i.e surrounded by wall) Closed(i.e surrounded by wall) Lets chose this(random)(we have two case jump i.e down and right) No permission to visited the surrounding wall of the whole maze (since the wall are not closed)

  12. Not Closed(i.e not surrounded by wall from left and down) and for another not surrounded by wall from left and right Closed(i.e surrounded by wall) Afer many successive recursion let this condition arrises No choice but to jump there No permission to visited the surrounding wall of the whole maze (since the wall are not closed)

  13. Not closed(that’s why we jump to next block to avoid unwanted recursion since there is no condition for visited block)such that backtracking can be done(i.e exiting from present recursion to back…. Again Afer many successive recursion let this condition arrises No choice but to backtrack to the condition where there are available closed block No permission to visited the surrounding wall of the whole maze (since the wall are not closed)

  14. closed Again Backtraking Occurs to available condition Move to available block No permission to visited the surrounding wall of the whole maze (since the wall are not closed)

  15. Again After many successive recursion let this final condition arises Not closed Now again backtracking occurs to the previous condition until there is a available condition……. No permission to visited the surrounding wall of the whole maze (since the wall are not closed)

  16. No available condition so…..backtracking occurs to the initial condition….. Now backtracking occurs to the initial position……After which the maze is entirely created….generated……. No permission to visited the surrounding wall of the whole maze (since the wall are not closed)

  17. Start Game Main Menu High score New Maze Instruction Credits Exit Maze Size Input End Game Gaming Rendering

  18. Problem Faced and Solution To find the algorithm for maze generator . To change the algorithm into real code. To convert 2D maze(2D array) into the 3D world. Collision Detection was the hardest part which was solved using Axis-Aligned Cubic Collision . Glut is a C library …so glut callbacks function accepts only the void function pointers…i.e function pointers to an instance of any class is not accepted by the callbacks. This was solved by creating a bridge/transition class(Engine class) and an anonymous namespace.

  19. Limitation Maximum size of the size is 35 .. To avoid fps drop……. There is no 2D view of the maze while playing(accepts while start). There is no 3D model (or animation) in our game. Older version of OpenGL(2.1) which does not support shader implementation and many more….

  20. Conclusion Making games is fun and we got to know about various aspects of programming. We learnt about team work and work division

More Related