# Coc (order: Dis, Geh, Coc, Tar)
##############################################################################
+: require('dlua/vault.lua')
+
{{
function coc_setup(e)
e.place("Coc:7")
e.set_feature_name("stone_wall", "ice-covered stone wall")
e.set_feature_name("floor", "Frost-covered floor")
end
-
--- the Serpent should appear in exactly one hell end
--- XXX: are things like shafts going to break this?
-function hell_branches_remaining()
- local hell_branches = { "Geh", "Coc", "Dis", "Tar" }
- local ret = #hell_branches
- for _, branch in pairs(hell_branches) do
- if travel.find_deepest_explored(branch) == 7 then
- ret = ret - 1
- end
- end
- return ret
-end
-
-function serpent_of_hell_setup(e)
- if not you.uniques("the Serpent of Hell") and
- crawl.one_chance_in(hell_branches_remaining()) then
- e.kmons('D = the Serpent of Hell')
- end
-end
}}
##############################################################################
# (order: Dis, Geh, Coc, Tar)
##############################################################################
-{{
+: require('dlua/vault.lua')
+{{
function dis_setup(e)
e.place("Dis:7")
e.tags("dis", "no_rotate")
e.kitem('O = iron rune of Zot')
end
--- the Serpent should appear in exactly one hell end
--- XXX: are things like shafts going to break this?
-function hell_branches_remaining()
- local hell_branches = { "Geh", "Coc", "Dis", "Tar" }
- local ret = #hell_branches
- for _, branch in pairs(hell_branches) do
- if travel.find_deepest_explored(branch) == 7 then
- ret = ret - 1
- end
- end
- return ret
-end
-
-function serpent_of_hell_setup(e)
- if not you.uniques("the Serpent of Hell") and
- crawl.one_chance_in(hell_branches_remaining()) then
- e.kmons('D = the Serpent of Hell')
- end
-end
-
function callback.grunt_iron_hall_animate(data,triggerable,trigger,marker,ev)
if not dgn.persist.grunt_iron_hall_animated then
dgn.persist.grunt_iron_hall_animated = true
e.tile("G = dngn_statue_iron")
e.set_feature_name("granite_statue", "iron statue")
end
-
}}
##############################################################################
# Geh (order: Dis, Geh, Coc, Tar)
##############################################################################
-{{
+: require('dlua/vault.lua')
+{{
function geh_setup(e)
e.place("Geh:7")
e.lflags("no_tele_control")
e.set_feature_name("floor", "Ashen ground")
e.set_feature_name("metal_wall", "tempered metal wall")
end
-
--- the Serpent should appear in exactly one hell end
--- XXX: are things like shafts going to break this?
-function hell_branches_remaining()
- local hell_branches = { "Geh", "Coc", "Dis", "Tar" }
- local ret = #hell_branches
- for _, branch in pairs(hell_branches) do
- if travel.find_deepest_explored(branch) == 7 then
- ret = ret - 1
- end
- end
- return ret
-end
-
-function serpent_of_hell_setup(e)
- if not you.uniques("the Serpent of Hell") and
- crawl.one_chance_in(hell_branches_remaining()) then
- e.kmons('D = the Serpent of Hell')
- end
-end
-
-function callback.grunt_iron_hall_animate(data,triggerable,trigger,marker,ev)
- if not dgn.persist.grunt_iron_hall_animated then
- dgn.persist.grunt_iron_hall_animated = true
- for slave in iter.slave_iterator("trap_statue", 1) do
- if crawl.one_chance_in(4) then
- dgn.terrain_changed(slave.x, slave.y, "floor", false, false, false)
- dgn.create_monster(slave.x, slave.y,
- "patrolling iron golem generate_awake")
- end
- end
- crawl.mpr("You hear the creaking of ancient metal!", "warning")
- end
-end
-
}}
# Tar (order: Dis, Geh, Coc, Tar)
##############################################################################
-{{
+: require('dlua/vault.lua')
+{{
function tar_setup(e)
e.place("Tar:7")
e.tags("no_rotate")
e.kitem('O = bone rune of Zot')
end
--- the Serpent should appear in exactly one hell end
--- XXX: are things like shafts going to break this?
-function hell_branches_remaining()
- local hell_branches = { "Geh", "Coc", "Dis", "Tar" }
- local ret = #hell_branches
- for _, branch in pairs(hell_branches) do
- if travel.find_deepest_explored(branch) == 7 then
- ret = ret - 1
- end
- end
- return ret
-end
-
-function serpent_of_hell_setup(e)
- if not you.uniques("the Serpent of Hell") and
- crawl.one_chance_in(hell_branches_remaining()) then
- e.kmons('D = the Serpent of Hell')
- end
-end
-
function callback.grunt_gauntlet_trap_activate(data,triggerable,trigger,marker,ev)
if not dgn.persist.grunt_gauntlet_trap_triggered then
for slave in iter.slave_iterator("trap_wall2", 1) do
e.subst("T : V")
end
end
+
+-- the Serpent should appear in exactly one hell end
+-- XXX: are things like shafts going to break this?
+function hell_branches_remaining()
+ local hell_branches = { "Geh", "Coc", "Dis", "Tar" }
+ local ret = #hell_branches
+ for _, branch in pairs(hell_branches) do
+ if travel.find_deepest_explored(branch) == 7 then
+ ret = ret - 1
+ end
+ end
+ return ret
+end
+
+function serpent_of_hell_setup(e)
+ if not you.uniques("the Serpent of Hell") and
+ crawl.one_chance_in(hell_branches_remaining()) then
+ e.kmons('D = the Serpent of Hell')
+ end
+end