diff options
-rw-r--r-- | crawl-ref/docs/level_design.txt | 25 | ||||
-rw-r--r-- | crawl-ref/source/dat/icecave.des | 14 | ||||
-rw-r--r-- | crawl-ref/source/dat/large.des | 6 | ||||
-rw-r--r-- | crawl-ref/source/dat/sewer.des | 2 |
4 files changed, 28 insertions, 19 deletions
diff --git a/crawl-ref/docs/level_design.txt b/crawl-ref/docs/level_design.txt index 4b3d501247..165716de98 100644 --- a/crawl-ref/docs/level_design.txt +++ b/crawl-ref/docs/level_design.txt @@ -24,27 +24,35 @@ the existing ones and modify them. Currently, the following .des files are in use: altar.des - minivaults containing altars + arena.des - arenas for the arena mode bazaar.des - entrances to bazaar portal vaults, and bazaars proper - crypt.des - Crypt:5, Tomb:1, Tomb:2, Tomb:3 - elf.des - Elf:7 + crypt.des - random vaults for Crypt, the Crypt:5 branch ends, and the + predefined maps for Tomb:1, Tomb:2 and Tomb:3 + didact.des - lua and vaults for syntax checking - not used in-game + dummy.des - global dummy balancers + elf.des - arrival and random vaults for Elf, and Elf:7 branch ends entry.des - entry vaults (each game - but not tutorial games - uses one of these premade maps for the vicinity of the entrance) float.des - floating vaults hells.des - hell entrances, Geryon's vestibule, Coc:7, Tar:7, Dis:7, Geh:7 - hive.des - hive entrances, Hive:4 + hive.des - hive entrances, random hive vaults, Hive:2 icecave.des - the ice cave portal vault lab.des - labyrinths exits and flavour vaults - lair.des - lair entrances, Shoals:5, Swamp:5, Snake:5, Slime:6 - large.des - all regular vaults which have ORIENT:encompass/northwest etc. - layout.des - Level layout code that has been moved from dungeon.cc and + lair.des - lair entrances, random vaults for lair proper and sub-branches, + and the branch ends: Shoals:5, Swamp:5, Snake:5, Slime:6 + large.des - all regular vaults which have ORIENT:encompass/northwest etc + layout.des - level layout code that has been moved from dungeon.cc and rewritten in Lua. mini.des - minivaults (no ORIENT line at all) minitomb.des - the minitomb portal vault orc.des - orcish mine entrances, orc only vaults pan.des - vaults of the Pan demon lords, Pan minivaults + rooms.des - special monster rooms, such as orc, kobold and jelly rooms sewer.des - the sewer portal vault temple.des - Ecumenical Temples, and Temple entrances - vaults.des - entrances for the Vaults, and Vaults:8 + vaults.des - entrances for the Vaults, Vaults-specific vaults, the + Hall of Blades, and Vaults:8 + ziggurat.des - the ziggurat entry vaults, pillars and arenas zot.des - vaults for the Zot branch and the maps for Zot:5 Kinds of Vaults @@ -1784,7 +1792,8 @@ original_map, glyphs_connected, orig_glyphs_connected, orig_gly_point, orig_gly_points, load_des_file, feature_number, feature_name, dgn_event_type, register_listener, remove_listener, remove_marker, num_matching_markers, feature_desc, feature_desc_at, item_from_index, -mons_from_index, change_level_flags, change_branch_flags +mons_from_index, change_level_flags, change_branch_flags, +set_random_mon_list Lua API - global game state diff --git a/crawl-ref/source/dat/icecave.des b/crawl-ref/source/dat/icecave.des index 8927340283..f85a8fa8b4 100644 --- a/crawl-ref/source/dat/icecave.des +++ b/crawl-ref/source/dat/icecave.des @@ -450,7 +450,7 @@ MONS: polar bear simulacrum w:3 generate_awake / \ MONS: ice statue ITEM: wand of frost / wand of cold w:5 ITEM: ring of ice / staff of cold -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then ITEM: manual of ice magic ITEM: nothing : else @@ -592,7 +592,7 @@ TAGS: ice_cave no_item_gen no_monster_gen no_pool_fixup WEIGHT: 5 ORIENT: encompass # A bit of layout randomization. -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then SUBST: ' = x SUBST: - = . SUBST: _ = . @@ -603,7 +603,7 @@ SUBST: _ = w : end : ice_cave_colours(_G) # Two different populations: undead/demon and natural/giant. -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then : ice_cave_random_monster_list_undead_demon(_G) : ice_cave_caverns_undead_demon_monster_set(_G) ITEM: cloak ego:fire_resistance good_item / wizard hat good_item / \ @@ -659,13 +659,13 @@ TAGS: ice_cave no_item_gen no_monster_gen no_pool_fixup WEIGHT: 5 ORIENT: encompass # Some layout randomization. -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then SUBST: '=x , -=. : else SUBST: '=. , -=x : end # Two different populations: undead/demon and natural/giant. -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then : ice_cave_random_monster_list_undead_demon(_G) : ice_cave_caverns_undead_demon_monster_set(_G) ITEM: cloak ego:fire_resistance good_item / wizard hat good_item / \ @@ -727,13 +727,13 @@ TAGS: ice_cave no_item_gen no_monster_gen no_pool_fixup WEIGHT: 5 ORIENT: encompass # A bit of layout randomization for the middle part. -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then SUBST: '=x , -=. : else SUBST: '=. , -=x : end # Two different populations: undead/demon and natural/giant. -: if crawl.random2(2) == 0 then +: if crawl.coinflip() then : ice_cave_random_monster_list_undead_demon(_G) : ice_cave_caverns_undead_demon_monster_set(_G) ITEM: cloak ego:fire_resistance good_item / wizard hat good_item / \ diff --git a/crawl-ref/source/dat/large.des b/crawl-ref/source/dat/large.des index 6b96b487da..0ddadfcd0e 100644 --- a/crawl-ref/source/dat/large.des +++ b/crawl-ref/source/dat/large.des @@ -217,7 +217,7 @@ DEPTH: D:3-14 # This chooses between closed+populated and open+deserted variations - # the populated version is more fun, the deserted version is easier. # Shallow vaults and some deeper ones get the deserted version: -: if you.absdepth()<7 or crawl.random2(6)==0 then +: if you.absdepth()<7 or crawl.one_chance_in(6) then SUBST: T=., A=., a=., M=., m=., H=., h=., F=., f=., S=., s=., B=. SUBST: b=., W=., w=., Z=., z=., G=., D=., d=. : end @@ -997,10 +997,10 @@ KMONS: z = killer bee KMONS: Z = bumblebee KITEM: z = royal jelly / honeycomb w:20 / nothing w:120 KITEM: Z = royal jelly / honeycomb w:20 / nothing w:120 -: if crawl.random2(3) == 0 then +: if crawl.one_chance_in(3) then KMONS: ! = orc / orc warrior / orc knight / nothing w:30 KMONS: & = orc warlord / orc knight / nothing w:20 -: elseif crawl.random2(2) == 0 then +: elseif crawl.coinflip() then KMONS: ! = yaktaur / nothing KMONS: & = yaktaur captain / nothing : else diff --git a/crawl-ref/source/dat/sewer.des b/crawl-ref/source/dat/sewer.des index af71f91c63..322a1c0634 100644 --- a/crawl-ref/source/dat/sewer.des +++ b/crawl-ref/source/dat/sewer.des @@ -153,7 +153,7 @@ NAME: sewer_kobolds TAGS: sewer no_item_gen no_monster_gen no_pool_fixup WEIGHT: 50 ORIENT: encompass -: if crawl.random2(12) == 0 then +: if crawl.one_chance_in(12) then SUBST: C=c, X=w, V=W, v=w, *=f : else SUBST: X=c, C=x, V=x, v=x, *=x |