Prim algorithm for the implementation of random mazes in videogames
DOI:
https://doi.org/10.15381/idata.v15i2.6375Keywords:
Prim, Mazes, Game, Graph.Abstract
The Prim's algorithm, extracted from the graph theory, is easily adaptable for generating random mazes in the game development process. This study provides the theoretical framework of the algorithm, its adaptation to generate two-dimensional arrays of values, coding in Java and use of libraries provided by this programming language. It restricts the creation of the arrays to a minimum size of 11x11 to ensure that generates coherent sizes mazes and its application is for generating orthogonal called labyrinths (2D view). Finally, the measurement is made of the performance of the proposed encoding and concludes that in all tests, the average response time is less than a tenth of a second to generate maps of labyrinths.
Downloads
Downloads
Published
Issue
Section
License
Copyright (c) 2012 Félix Melchor Santos López, Eulogio Santos De La Cruz
![Creative Commons License](http://i.creativecommons.org/l/by-nc-sa/4.0/88x31.png)
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
AUTHORS RETAIN THEIR RIGHTS:
a. Authors retain their trade mark rights and patent, and also on any process or procedure described in the article.
b. Authors retain their right to share, copy, distribute, perform and publicly communicate their article (eg, to place their article in an institutional repository or publish it in a book), with an acknowledgment of its initial publication in the INDUSTRIAL DATA.
c. Authors retain theirs right to make a subsequent publication of their work, to use the article or any part thereof (eg a compilation of his papers, lecture notes, thesis, or a book), always indicating the source of publication (the originator of the work, journal, volume, number and date).