Difference between revisions of "Complete roguelike tutorial using C++ and libtcod - part 3: dungeon building"
Jump to navigation
Jump to search
(pasted →top: and sidebar) |
|||
Line 1: | Line 1: | ||
{{Complete roguelike tutorial using C++ and libtcod}} | {{Complete roguelike tutorial using C++ and libtcod}} | ||
In this article, we will improve the Map class to generate a real dungeon with rooms and corridors. We'll use a very simple dungeon generator, using a straightforward way to connect rooms together. This will result in "winnable" dungeons (no room disconnected) but with a slightly chaotic look. For a better corridor connection, check the libtcod C++ samples in the libtcod/samples/ directory. | In this article, we will improve the Map class to generate a real dungeon with rooms and corridors. We'll use a very simple dungeon generator, using a straightforward way to connect rooms together. This will result in "winnable" dungeons (no room disconnected) but with a slightly chaotic look. For a better corridor connection, check the libtcod C++ samples in the libtcod/samples/ directory. | ||
==libtcod functions used in this article== | |||
[http://roguecentral.org/doryen/data/libtcod/doc/1.5.1/html2/random_init.html?c=false&cpp=true&cs=false&py=false&lua=false#0 TCODRandom::getInstance] | |||
[http://roguecentral.org/doryen/data/libtcod/doc/1.5.1/html2/random_use.html?c=false&cpp=true&cs=false&py=false&lua=false#0 TCODRandom::getInt] | |||
[http://roguecentral.org/doryen/data/libtcod/doc/1.5.1/html2/bsp_init.html?c=false&cpp=true&cs=false&py=false&lua=false TCODBsp::TCODBsp] | |||
[http://roguecentral.org/doryen/data/libtcod/doc/1.5.1/html2/bsp_split.html?c=false&cpp=true&cs=false&py=false&lua=false#1 TCODBsp::splitRecursive] | |||
[http://roguecentral.org/doryen/data/libtcod/doc/1.5.1/html2/bsp_traverse.html?c=false&cpp=true&cs=false&py=false&lua=false TCODBsp::traverseInvertedLevelOrder] |
Revision as of 11:41, 29 September 2015
Complete roguelike tutorial using C++ and libtcod -originally written by Jice Text in this tutorial was released under the Creative Commons Attribution-ShareAlike 3.0 Unported and the GNU Free Documentation License (unversioned, with no invariant sections, front-cover texts, or back-cover texts) on 2015-09-21. |
---|
|
In this article, we will improve the Map class to generate a real dungeon with rooms and corridors. We'll use a very simple dungeon generator, using a straightforward way to connect rooms together. This will result in "winnable" dungeons (no room disconnected) but with a slightly chaotic look. For a better corridor connection, check the libtcod C++ samples in the libtcod/samples/ directory.