1 -- NetHack 3.7 mines minetn-1.lua $NHDT-Date: 1652196030 2022/05/10 15:20:30 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.8 $
2 -- Copyright (c) 1989-95 by Jean-Christophe Collet
3 -- Copyright (c) 1991-95 by M. Stephenson
4 -- NetHack may be freely redistributed. See license for details.
6 -- A tragic accident has occurred in Frontier Town....
9 -- Orcish Town - a variant of Frontier Town that has been
10 -- overrun by orcs. Note the barricades (iron bars).
12 des
.level_flags("mazelevel")
14 des
.level_init({ style
="mines", fg
=".", bg
=" ", smoothed
=true, joined
=true, walled
=true })
17 .....................................
18 .----------------F------------------.
19 .|.................................|.
20 .|.-------------......------------.|.
21 .|.|...|...|...|......|..|...|...|.|.
22 .F.|...|...|...|......|..|...|...|.|.
23 .|.|...|...|...|......|..|...|...|.F.
24 .|.|...|...|----......------------.|.
25 .|.---------.......................|.
26 .|.................................|.
27 .|.---------.....--...--...........|.
28 .|.|...|...|----.|.....|.---------.|.
29 .|.|...|...|...|.|.....|.|..|....|.|.
30 .|.|...|...|...|.|.....|.|..|....|.|.
31 .|.|...|...|...|.|.....|.|..|....|.|.
32 .|.-------------.-------.---------.|.
33 .|.................................F.
34 .-----------F------------F----------.
35 .....................................
38 -- Don't let the player fall into his likely death; used to explicitly exclude
39 -- the town, but that meant that you couldn't teleport out as well as not in.
40 des
.teleport_region({ region
={01,01,75,19}, exclude
={01,00,35,21}, region_islev
=1 })
41 des
.region(selection
.area(01,01,35,17), "lit")
42 des
.levregion({ type="stair-up", region
={01,03,21,19}, region_islev
=1,
43 exclude
={00,01,36,17} });
44 des
.levregion({ type="stair-down", region
={57,03,75,19}, region_islev
=1,
45 exclude
={00,01,36,17} })
47 -- shame we can't make polluted fountains
48 des
.feature("fountain",16,09)
49 des
.feature("fountain",25,09)
51 -- the altar's defiled; useful for BUC but never coaligned
52 des
.altar({ x
=20,y
=13,align
="noalign", type="shrine" })
54 -- set up the shop doors; could be broken down
55 des
.door("random",5,8)
56 des
.door("random",9,8)
57 des
.door("random",13,7)
58 des
.door("random",22,5)
59 des
.door("random",27,7)
60 des
.door("random",31,7)
61 des
.door("random",5,10)
62 des
.door("random",9,10)
63 des
.door("random",15,13)
64 des
.door("random",25,13)
65 des
.door("random",31,11)
67 -- knock a few holes in the shop interior walls
68 des
.replace_terrain({ region
={07,04,11,06}, fromterrain
="|", toterrain
=".", chance
=18 })
69 des
.replace_terrain({ region
={25,04,29,06}, fromterrain
="|", toterrain
=".", chance
=18 })
70 des
.replace_terrain({ region
={07,12,11,14}, fromterrain
="|", toterrain
=".", chance
=18 })
71 des
.replace_terrain({ region
={28,12,28,14}, fromterrain
="|", toterrain
=".", chance
=33 })
73 -- One spot each in most shops...
74 local place
= { {05,04},{09,05},{13,04},{26,04},{31,05},{30,14},{05,14},{10,13},{26,14},{27,13} }
77 -- scatter some bodies
78 des
.object({ id
= "corpse", x
=20,y
=12, montype
="aligned cleric" })
79 des
.object({ id
= "corpse", coord
= place
[1], montype
="shopkeeper" })
80 des
.object({ id
= "corpse", coord
= place
[2], montype
="shopkeeper" })
81 des
.object({ id
= "corpse", coord
= place
[3], montype
="shopkeeper" })
82 des
.object({ id
= "corpse", coord
= place
[4], montype
="shopkeeper" })
83 des
.object({ id
= "corpse", coord
= place
[5], montype
="shopkeeper" })
84 des
.object({ id
= "corpse", montype
="watchman" })
85 des
.object({ id
= "corpse", montype
="watchman" })
86 des
.object({ id
= "corpse", montype
="watchman" })
87 des
.object({ id
= "corpse", montype
="watchman" })
88 des
.object({ id
= "corpse", montype
="watch captain" })
91 for i
=1,9 + math
.random(2 - 1,2*5) do
98 -- Guarantee 7 candles since we won't have Izchak available
99 des
.object({ id
= "wax candle", coord
= place
[4], quantity
= math
.random(1,2) })
101 des
.object({ id
= "wax candle", coord
= place
[1], quantity
= math
.random(2,4) })
102 des
.object({ id
= "wax candle", coord
= place
[2], quantity
= math
.random(1,2) })
103 des
.object({ id
= "tallow candle", coord
= place
[3], quantity
= math
.random(1,3) })
104 des
.object({ id
= "tallow candle", coord
= place
[2], quantity
= math
.random(1,2) })
105 des
.object({ id
= "tallow candle", coord
= place
[4], quantity
= math
.random(1,2) })
107 -- go ahead and leave a lamp next to one corpse to be suggestive
108 -- and some empty wands...
109 des
.object("oil lamp",place
[2])
110 des
.object({ id
= "wand of striking", coord
= place
[1], buc
="uncursed", spe
=0 })
111 des
.object({ id
= "wand of striking", coord
= place
[3], buc
="uncursed", spe
=0 })
112 des
.object({ id
= "wand of striking", coord
= place
[4], buc
="uncursed", spe
=0 })
113 des
.object({ id
= "wand of magic missile", coord
= place
[4], buc
="uncursed", spe
=0 })
114 des
.object({ id
= "wand of magic missile", coord
= place
[5], buc
="uncursed", spe
=0 })
118 local inside
= selection
.floodfill(18,8)
119 local near_temple
= selection
.area(17,8, 23,14) & inside
121 for i
=1,5 + math
.random(1 - 1,1*10) do
123 des
.monster({ id
= "orc-captain", coord
= inside
:rndcoord(1), peaceful
=0 });
126 des
.monster({ id
= "Uruk-hai", coord
= inside
:rndcoord(1), peaceful
=0 })
128 des
.monster({ id
= "Mordor orc", coord
= inside
:rndcoord(1), peaceful
=0 })
132 -- shamans can be hanging out in/near the temple
133 for i
=1,math
.random(2 - 1,2*3) do
134 des
.monster({ id
= "orc shaman", coord
= near_temple
:rndcoord(0), peaceful
=0 });
136 -- these are not such a big deal
137 -- to run into outside the bars
138 for i
=1,9 + math
.random(2 - 1,2*5) do
140 des
.monster({ id
= "hill orc", peaceful
= 0 })
142 des
.monster({ id
= "goblin", peaceful
= 0 })
146 -- Hack to force full-level wallification