Difference between revisions of "Room"
(clear out most of 2007-era original article text since it was poorly written, was documented elsewhere, or was pointless (e.g. describing the anatomy of a room); rewrite strategy section) |
|||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | + | '''Rooms''' are a feature ubiquitous in [[NetHack]]. A room is an area, usually rectangular, that is separated from other areas by [[wall]]s and is typically paved with [[floor]] terrain. | |
− | '''Rooms''' are a feature ubiquitous in [[NetHack]] | ||
− | |||
− | |||
+ | The [[Dungeons of Doom]] consist mostly of "room-and-corridor" levels, containing a number of rooms connected by [[corridor]]s. Some rooms contain [[stairs]], which connect different levels to each other. They also may contain [[dungeon feature]]s, [[monster]]s, [[objects]], and [[traps]], or may be turned into a [[special room]]. | ||
------ -------- ------- | ------ -------- ------- | ||
− | #.... | + | #......#######|.......########+.....| ------ ------- |
− | #|....| #|.....<| |>....| ##.. | + | #|....| #|.....<| |>....| ##.....| |.....| |
− | #|.....# #|......| |.... | + | #|.....# #|......| |.....| |....| #+.....| |
− | #|....|# #|.... | + | #|....|# #|......| ---.-.- #+....| #|.....| |
#------# #|......| # # ###----|- #|.....| | #------# #|......| # # ###----|- #|.....| | ||
# # # #---.---- # ### # #### #------- | # # # #---.---- # ### # #### #------- | ||
Line 16: | Line 14: | ||
# # # # ##### # ### ### # | # # # # ##### # ### ### # | ||
# # # -.-----+----### # # # | # # # -.-----+----### # # # | ||
− | # ### # |... | + | # ### # |..........|# ######## # |
# # # |...........# ------.-.---# | # # # |...........# ------.-.---# | ||
-----# ### # # |..........| |...........# | -----# ### # # |..........| |...........# | ||
|....# # ------.---- ------------ |..........| | |....# # ------.---- ------------ |..........| | ||
|...| ##+.........| |..........| | |...| ##+.........| |..........| | ||
− | | | + | |...| |..........################ ------------ |
− | ----- |. | + | ----- |.........| # |
− | # |. | + | # |.........| |
----------- | ----------- | ||
− | == | + | == Generation == |
− | + | This section covers only typical non-special, room-and-corridor levels in the [[Dungeons of Doom]]. Rooms also appear in special levels and certain [[Quest]] filler levels, but those typically do not have the random generation described below. | |
− | + | On each level, a number of rooms will be generated, and then they will be connected up by [[corridor]]s and [[door]]s. The algorithm for placing rooms makes it difficult to predict how many rooms a level will contain, but most levels contain between 5 and 10 rooms, with occasional appearances of levels with as few as 4 or as many as 12. On these levels, one room may be selected to become a [[special room]]. | |
− | + | [[Vault]]s are a special case: they do not count as a special room despite technically being one, and they are not connected to the rest of the level by corridors. | |
− | |||
− | + | {{upcoming|NetHack 3.7.0|Each level will also generate up to two [[themed room]]s, which can be irregularly shaped or contain interesting contents and terrain.}} | |
− | + | There tends to be a fixed rather than area-based chance of generating dungeon features, monsters, objects, and traps in each non-special room. Therefore, a level with more rooms will contain more of these things. | |
− | |||
+ | === Lit rooms === | ||
+ | <!-- Math: | ||
+ | "Lit check 1": rnd(1 + depth) < 11. Always true above level 10. On level 10, there is a 10/11 chance of passing this check; on level 11 there is a 10/12 chance, etc. | ||
+ | "Lit check 2": rn2(77). Fixed 76/77 chance. | ||
+ | Both lit checks must pass in order for a room to be lit. | ||
+ | --> | ||
+ | Rooms generate either as lit or unlit, meaning that every square in a room will be lit up or dark. The chance of a room being lit depends solely on the [[level difficulty]], with fewer lit rooms deeper into the dungeon:{{refsrc|src/sp_lev.c|1154|nethack=3.6.6}} | ||
− | + | Level 9 or above: <math>\frac{76}{77}</math> | |
− | |||
+ | Level 10 or below: <math>\frac{76}{77}\cdot\frac{10}{\text{difficulty} + 1}</math> | ||
− | == | + | == Strategy == |
− | + | Finding rooms is not always straightforward. If you see no obvious way forward, common tactics include: | |
+ | * Be persistent in [[search]]ing. If you can identify a large unexplored area of the map, more rooms may be hidden there. Search along the edges of this area, especially the walls of known rooms. Failing that, be aware that rooms can be as small as 2x3 and hence tucked into places you would not expect them. | ||
+ | * Try using the [[terrain]] command to show the map without monsters or objects - the stairs may be hidden under a monster or object. | ||
+ | * Use [[magic mapping]]. | ||
+ | * Fall down a [[pit]] or [[hole]] to go to a lower level, then explore back up. | ||
+ | == References == | ||
+ | <references /> | ||
− | |||
− | |||
[[Category:Dungeon features]] | [[Category:Dungeon features]] | ||
− | {{nethack- | + | {{nethack-366}} |
Latest revision as of 01:47, 27 July 2020
Rooms are a feature ubiquitous in NetHack. A room is an area, usually rectangular, that is separated from other areas by walls and is typically paved with floor terrain.
The Dungeons of Doom consist mostly of "room-and-corridor" levels, containing a number of rooms connected by corridors. Some rooms contain stairs, which connect different levels to each other. They also may contain dungeon features, monsters, objects, and traps, or may be turned into a special room.
------ -------- ------- #......#######|.......########+.....| ------ ------- #|....| #|.....<| |>....| ##.....| |.....| #|.....# #|......| |.....| |....| #+.....| #|....|# #|......| ---.-.- #+....| #|.....| #------# #|......| # # ###----|- #|.....| # # # #---.---- # ### # #### #------- # # ######### ### # ### # # #### # # # # ##### # ### ### # # # # -.-----+----### # # # # ### # |..........|# ######## # # # # |...........# ------.-.---# -----# ### # # |..........| |...........# |....# # ------.---- ------------ |..........| |...| ##+.........| |..........| |...| |..........################ ------------ ----- |.........| # # |.........| -----------
Contents
Generation
This section covers only typical non-special, room-and-corridor levels in the Dungeons of Doom. Rooms also appear in special levels and certain Quest filler levels, but those typically do not have the random generation described below.
On each level, a number of rooms will be generated, and then they will be connected up by corridors and doors. The algorithm for placing rooms makes it difficult to predict how many rooms a level will contain, but most levels contain between 5 and 10 rooms, with occasional appearances of levels with as few as 4 or as many as 12. On these levels, one room may be selected to become a special room.
Vaults are a special case: they do not count as a special room despite technically being one, and they are not connected to the rest of the level by corridors.
The following information pertains to an upcoming version (NetHack 3.7.0). If this version is now released, please verify that it is still accurate, then update the page to incorporate this information.
Each level will also generate up to two themed rooms, which can be irregularly shaped or contain interesting contents and terrain.There tends to be a fixed rather than area-based chance of generating dungeon features, monsters, objects, and traps in each non-special room. Therefore, a level with more rooms will contain more of these things.
Lit rooms
Rooms generate either as lit or unlit, meaning that every square in a room will be lit up or dark. The chance of a room being lit depends solely on the level difficulty, with fewer lit rooms deeper into the dungeon:[1]
Level 9 or above:
Level 10 or below:
Strategy
Finding rooms is not always straightforward. If you see no obvious way forward, common tactics include:
- Be persistent in searching. If you can identify a large unexplored area of the map, more rooms may be hidden there. Search along the edges of this area, especially the walls of known rooms. Failing that, be aware that rooms can be as small as 2x3 and hence tucked into places you would not expect them.
- Try using the terrain command to show the map without monsters or objects - the stairs may be hidden under a monster or object.
- Use magic mapping.
- Fall down a pit or hole to go to a lower level, then explore back up.