Source:NetHack 5.0.0/dat/valley.lua

From NetHackWiki
Jump to navigation Jump to search

Below is the full text to valley.lua from the source code of NetHack 5.0.0. To link to a particular line, write [[Source:NetHack 5.0.0/dat/valley.lua#line12]], for example.

The NetHack General Public License applies to screenshots, source code and other content from NetHack.

This content was modified from the original NetHack source code distribution (by splitting up NetHack content between wiki pages, and possibly further editing). See the page history for a list of who changed it, and on what dates.

1. -- NetHack gehennom valley.lua	$NHDT-Date: 1652196038 2022/05/10 15:20:38 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.4 $
2. --	Copyright (c) 1989 by Jean-Christophe Collet
3. --	Copyright (c) 1992 by M. Stephenson and Izchak Miller
4. -- NetHack may be freely redistributed.  See license for details.
5. --
6. --
7. 
8. des.level_init({ style = "solidfill", fg = " " });
9. 
10. des.level_flags("mazelevel", "noteleport", "hardfloor", "nommap", "temperate");
11. 
12. des.map([[
13. ----------------------------------------------------------------------------
14. |...S.|..|.....|  |.....-|      |................|   |...............| |...|
15. |---|.|.--.---.|  |......--- ----..........-----.-----....---........---.-.|
16. |   |.|.|..| |.| --........| |.............|   |.......---| |-...........--|
17. |   |...S..| |.| |.......-----.......------|   |--------..---......------- |
18. |----------- |.| |-......| |....|...-- |...-----................----       |
19. |.....S....---.| |.......| |....|...|  |..............-----------          |
20. |.....|.|......| |.....--- |......---  |....---.......|                    |
21. |.....|.|------| |....--   --....-- |-------- ----....---------------      |
22. |.....|--......---BBB-|     |...--  |.......|    |..................|      |
23. |..........||........-|    --...|   |.......|    |...||.............|      |
24. |.....|...-||-........------....|   |.......---- |...||.............--     |
25. |.....|--......---...........--------..........| |.......---------...--    |
26. |.....| |------| |--.......--|   |..B......----- -----....| |.|  |....---  |
27. |.....| |......--| ------..| |----..B......|       |.--------.-- |-.....---|
28. |------ |........|  |.|....| |.....----BBBB---------...........---.........|
29. |       |........|  |...|..| |.....|  |-.............--------...........---|
30. |       --.....-----------.| |....-----.....----------     |.........----  |
31. |        |..|..B...........| |.|..........|.|              |.|........|    |
32. ----------------------------------------------------------------------------
33. ]]);
34. 
35. -- Make the path somewhat unpredictable
36. -- If you get "lucky", you may have to go through all three graveyards.
37. if percent(50) then
38.    des.terrain(selection.line(50,8, 53,8), '-')
39.    des.terrain(selection.line(40,8, 43,8), 'B')
40. end
41. if percent(50) then
42.    des.terrain({ x=27, y=12, typ='|' })
43.    des.terrain(selection.line(27,3, 29,3), 'B')
44.    des.terrain({ x=28, y=2, typ='-' })
45. end
46. if percent(50) then
47.    des.terrain(selection.line(16,10, 16,11), '|')
48.    des.terrain(selection.line(9,13, 14,13), 'B')
49. end
50. 
51. 
52. -- Dungeon Description
53. -- The shrine to Moloch.
54. des.region({ region={01,06, 05,14},lit=1,type="temple",filled=2 })
55. -- The Morgues
56. des.region({ region={19,01, 24,08},lit=0,type="morgue",filled=1,irregular=1 })
57. des.region({ region={09,14, 16,18},lit=0,type="morgue",filled=1,irregular=1 })
58. des.region({ region={37,09, 43,14},lit=0,type="morgue",filled=1,irregular=1 })
59. -- Stairs
60. des.stair("down", 01,01)
61. -- Branch location
62. des.levregion({ type="branch", region={66,17,66,17} })
63. des.teleport_region({ region = {58,09,72,18}, dir="down" })
64. 
65. -- Secret Doors
66. des.door("locked",04,01)
67. des.door("locked",08,04)
68. des.door("locked",06,06)
69. 
70. -- The altar of Moloch.
71. des.altar({ x=03,y=10,align="noalign", type="shrine" })
72. 
73. -- Non diggable walls - everywhere!
74. des.non_diggable(selection.area(00,00,75,19))
75. 
76. -- Objects
77. -- **LOTS** of dead bodies (all human).
78. -- note: no priest(esse)s or monks - maybe Moloch has a *special*
79. --       fate reserved for members of *those* classes.
80. --
81. des.object({ id="corpse",montype="archeologist" })
82. des.object({ id="corpse",montype="archeologist" })
83. des.object({ id="corpse",montype="barbarian" })
84. des.object({ id="corpse",montype="barbarian" })
85. des.object({ id="corpse",montype="caveman" })
86. des.object({ id="corpse",montype="cavewoman" })
87. des.object({ id="corpse",montype="healer" })
88. des.object({ id="corpse",montype="healer" })
89. des.object({ id="corpse",montype="knight" })
90. des.object({ id="corpse",montype="knight" })
91. des.object({ id="corpse",montype="ranger" })
92. des.object({ id="corpse",montype="ranger" })
93. des.object({ id="corpse",montype="rogue" })
94. des.object({ id="corpse",montype="rogue" })
95. des.object({ id="corpse",montype="samurai" })
96. des.object({ id="corpse",montype="samurai" })
97. des.object({ id="corpse",montype="tourist" })
98. des.object({ id="corpse",montype="tourist" })
99. des.object({ id="corpse",montype="valkyrie" })
100. des.object({ id="corpse",montype="valkyrie" })
101. des.object({ id="corpse",montype="wizard" })
102. des.object({ id="corpse",montype="wizard" })
103. --
104. -- Some random weapons and armor.
105. --
106. des.object("[")
107. des.object("[")
108. des.object("[")
109. des.object("[")
110. des.object(")")
111. des.object(")")
112. des.object(")")
113. des.object(")")
114. --
115. -- Some random loot.
116. --
117. des.object("ruby")
118. des.object("*")
119. des.object("*")
120. des.object("!")
121. des.object("!")
122. des.object("!")
123. des.object("?")
124. des.object("?")
125. des.object("?")
126. des.object("/")
127. des.object("/")
128. des.object("=")
129. des.object("=")
130. des.object("+")
131. des.object("+")
132. des.object("(")
133. des.object("(")
134. des.object("(")
135. 
136. -- (Not so) Random traps.
137. des.trap("spiked pit", 05,02)
138. des.trap("spiked pit", 14,05)
139. des.trap("sleep gas", 03,01)
140. des.trap("board", 21,12)
141. des.trap("board")
142. des.trap("dart", 60,01)
143. des.trap("dart", 26,17)
144. des.trap("anti magic")
145. des.trap("anti magic")
146. des.trap("magic")
147. des.trap("magic")
148. 
149. -- Random monsters.
150. -- The ghosts.
151. des.monster("ghost")
152. des.monster("ghost")
153. des.monster("ghost")
154. des.monster("ghost")
155. des.monster("ghost")
156. des.monster("ghost")
157. -- Add a few bats for atmosphere.
158. des.monster("vampire bat")
159. des.monster("vampire bat")
160. des.monster("vampire bat")
161. -- And a lich for good measure.
162. des.monster("L")
163. -- Some undead nasties for good measure
164. des.monster("V")
165. des.monster("V")
166. des.monster("V")
167. des.monster("Z")
168. des.monster("Z")
169. des.monster("Z")
170. des.monster("Z")
171. des.monster("M")
172. des.monster("M")
173. des.monster("M")
174. des.monster("M")