Skip to content
Snippets Groups Projects
Commit 4de8cb50 authored by Lisa Greene's avatar Lisa Greene
Browse files

Add revamped bandit fortress vault

parent aa4b56c0
No related branches found
No related tags found
No related merge requests found
......@@ -641,20 +641,25 @@ Love, #{italic}#Eden#{normal}#]]
}
newLore{
id = "renegade-pyromancers-vault",
id = "bandit-vault-guard",
category = "vault",
name = _t"How to Summon a Phoenix",
lore = _t[[#{bold}#How to Summon a Phoenix#{normal}#
10 pouches faeros ash
5 vials fire wyrm saliva
3 red crystal shards
3 pouches bone giant dust
1 vial greater demon bile
1 skeleton mage skull
pinch of luminous horror dust
#{italic}#The bottom half of the scroll has been singed into a pile of char, dispersing into a cloud of ash as you grasp it#{normal}#
]]
name = _t"Guard's Journal",
lore = _t[[Sixth time this week stuck guarding at the stash. And for what? Just a little fun!
Almost miss being at the farm sometimes. At least there I wasn't able to screw anything up. Wonder if they would take me back knowing what I've been doing with my life...]]
}
newLore{
id = "bandit-vault-boss",
category = "vault",
name = _t"Boss's Journal",
lore = _t[[The best haul we ever got, gone. We could have been set for life, the most legendary outlaws in all the lands! Villages would tremble at the thought of us roaming the woods.
Only a matter of time until that nobleman catches wind and comes after us. We were about to get more gold than we could count for his lassie back, and that dirt farmer set her on fire. Of all the skullbrained things to do for fun!
Ordered my men to kill any who pass by and been running triple guard. We need all the time we can get before they come for us, can't let any word out. Once we find somewhere new, I'll leave that idiot burnt on a stake as tribute and hope we don't catch chase.
I'm going to enjoy hearing his screams, a log on the pyre a gold he cost us. Nice and slow, need to make sure he doesn't die easy.]]
}
newLore{
......
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009 - 2019 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
setStatusAll{no_teleport=true, vault_only_door_open=true, room_map = {can_open=true}}
--setStatusAll{no_teleport=true, vault_only_door_open=true, room_map = {special=false, can_open=true}}
unique = "bandit-fortress" -- one per map
--startx, starty = 40, 19
border = 0
roomcheck = function(room, zone, level, map) -- one per zone, level restricted
return not zone._bandit_fortress and resolvers.current_level >= 10 and zone.npc_list.__loaded_files["/data/general/npcs/thieve.lua"]
end
specialList("actor", {
"/data/general/npcs/fire-drake.lua",
"/data/general/npcs/aquatic_critter.lua",
"/data/general/npcs/minotaur.lua",
"/data/general/npcs/troll.lua",
"/data/general/npcs/thieve.lua",
})
onplace = function(room, zone, level, map, data) -- flag the map as having this vault
map._bandit_fortress = level.level
end
onGenerated(function(zone, level, map) -- update the zone after the vault is placed (in case the level was regenerated)
if map._bandit_fortress == level.level then
zone._bandit_fortress = level.level
end
end
)
rotates = {"default", "90", "180", "270", "flipx", "flipy"}
defineTile('%', "WALL")
defineTile('.', "FLOOR")
defineTile('#', "HARDWALL")
defineTile('+', "DOOR")
defineTile('X', "DOOR_VAULT")
defineTile('~', "DEEP_WATER")
defineTile('*', "FLOOR", {random_filter={type="gem"}})
defineTile('$', "FLOOR", {random_filter={add_levels=25, type="money"}})
defineTile('/', "FLOOR", {random_filter={add_levels=5, tome_mod="vault"}})
defineTile('x', "FLOOR", {random_filter={add_levels=10, tome_mod="vault"}})
defineTile('L', "FLOOR", {random_filter={add_levels=15, tome_mod="gvault"}})
defineTile('^', "FLOOR", nil, nil, {random_filter={add_levels=20}})
defineTile('D', "FLOOR", nil, {random_filter={add_levels=15, name = "fire drake"}})
defineTile('p', "FLOOR", nil, {random_filter={add_levels=5, name = "assassin"}})
defineTile('P', "FLOOR", nil, {random_filter={add_levels=10, name = "bandit lord"}})
defineTile('H', "FLOOR", nil, {random_filter={add_levels=10, subtype = "minotaur"}})
defineTile('T', "FLOOR", nil, {random_filter={add_levels=20, subtype = "troll"}})
defineTile('A', "DEEP_WATER", nil, {random_filter={add_levels=10, type = "aquatic", subtype = "critter",}})
return {
[[........................................]],
[[.##########~~~~~~~~~~~~~~~~~~##########.]],
[[.#.p.....p#~~~A~~~~~~~~~~~~~~#.....p..#.]],
[[.#.######.#~~~~~~~~~~~~~~~~~~#.######.#.]],
[[.#.#xxxx#.#~~~~~~~~~A~~~~~A~~#.#xxx.#.#.]],
[[.#p#HHHH#.####################p#TTTT#p#.]],
[[.#.#pppP#.#*$$pH.+.#HLH.D..+^#.#HHHH#.#.]],
[[.#.#....#p#$*$pH.#.#LHH.D..#^#.#xxx.#.#.]],
[[.#.###+##.########.#########.#.##+###.#.]],
[[.#..p.....#..DDLL#.%.........+.p....p.#.]],
[[.#####+####%######+####################.]],
[[~A~~~#.#**#^.../$#P.....p....+.pp/#~~~~~]],
[[~~~~~#.#**#$.../$#.p.......p.#.pP/#~A~~~]],
[[~~~~~#.#**#$.../$#...p.....p.#ppp/#~~~~~]],
[[~~~~~#.#%%###+##############+#+####~~~~~]],
[[~~A~~#..HH#..p#.T............#////#~~~A~]],
[[~~~~~#....#p..#......T...p...#////#~~~~~]],
[[~~~~~#....#..p#..P...........######~~~~~]],
[[A~~~~#...P#...+T.....H....T...p...X.H...]],
[[~~~~~#P...#####...................X.T...]],
[[~~~~~#P...#####..T....p...p.......X.T...]],
[[~~~~~#...P#HH.+....H.........p....X.H...]],
[[~~~~~#....#.P.#..........T...######~~~~~]],
[[~~~~A#..HH#..p#...P...p......#////#~A~~~]],
[[~~~~~#..^^#p.^#T....T........#////#~~~~~]],
[[~~~~~#.#%%###+##############+#+####~~~~~]],
[[~~A~~#.#**#xxxxxD#.p.......P.#ppp/#A~~~~]],
[[~~~~~#.#**########.....p.....#.pP/#~~~A~]],
[[~~~~~#.#**%DDDLLL#.p.....p...+.pp/#~~~~~]],
[[.#####+###########+####################.]],
[[.#.p....p.+..P......H....TT..+.....p..#.]],
[[.#.###+##.#.....p......p..TT^#.##+###.#.]],
[[.#.#....#.#%################%#p#xxx.#.#.]],
[[.#.#pppP#.#....DDLL#LLDD.....#.#TTTT#.#.]],
[[.#p#HHHH#.####################.#HHHH#p#.]],
[[.#.#xxxx#p#~~~~A~~~~~~~~~A~~~#.#xxx.#.#.]],
[[.#.######.#~~~~~~~~~~~~~~~~~~#.######.#.]],
[[.#..p.....#~~~~~~~~~~~~~~~~A~#p...p...#.]],
[[.##########~~~~~A~~~~~~~~~~~~##########.]],
[[........................................]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009 - 2019 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
local Talents = require("engine.interface.ActorTalents")
unique = "bandit-fortress" -- one per map
setStatusAll{no_teleport=true, vault_only_door_open=true, room_map = {can_open=true}}
onplace = function(room, zone, level, map, data) -- flag the map as having this vault
map._bandit_fortress = level.level
end
onGenerated(function(zone, level, map) -- update the zone after the vault is placed (in case the level was regenerated)
if map._bandit_fortress == level.level then
zone._bandit_fortress = level.level
end
end
)
local stairs = function()
local terrains = mod.class.Grid:loadList("/data/general/grids/basic.lua")
return game.state:dynamicZoneEntry(terrains.UP, "bandit-fortress", {
name = _t"bandit fortress",
level_range = {game.zone.base_level, game.zone.base_level},
__applied_difficulty = true, -- Difficulty already applied to parent zone
level_scheme = "player",
max_level = 1,
actor_adjust_level = function(zone, level, e) return zone.base_level + e:getRankLevelAdjust() + level.level+4 + rng.range(-2,6) end,
width = 35, height = 60,
ambient_music = "Swashing the buck.ogg", -- check for better fit
persistent = "zone",
no_worldport = true,
min_material_level = util.getval(game.zone.min_material_level) + 1, -- vaults have better loot! acts as reward to compensate for the significant difficulty
max_material_level = util.getval(game.zone.max_material_level) + 1,
generator = {
map = {
class = "engine.generator.map.Static",
map = "zones/bandit-fortress",
},
trap = { nb_trap = {0, 0} },
object = { nb_object = {0, 0} },
actor = { nb_npc = {0, 0} },
}
}, {
npc_list = {"/data/general/npcs/thieve.lua"},
object_list = {"/data/general/objects/objects.lua"},
grid_list = {"/data/general/grids/basic.lua"},
trap_list = {"/data/general/traps/natural_forest.lua"},
},
function(zone, goback)
goback(_t"stairs back to %s", zone.grid_list.DOWN)
end)
end
specialList("terrain", {
"/data/general/grids/water.lua",
"/data/general/grids/forest.lua",
}, true)
border = 0
rotates = {"default", "90", "180", "270", "flipx", "flipy"}
defineTile('.', "FLOOR")
defineTile(',', "GRASS")
defineTile('#', "HARDWALL")
defineTile('+', "DOOR")
defineTile('!', "DOOR_VAULT")
defineTile('f', function() if rng.percent(35) then return "FLOWER" else return "GRASS" end end) -- so pretty, so beautiful <3
defineTile('~', "DEEP_WATER")
defineTile('#', "WALL")
defineTile('X', "TREE")
specialList("actor", {
"/data/general/npcs/thieve.lua",
"/data/general/npcs/minotaur.lua",
"/data/general/npcs/troll.lua",
})
specialList("trap", {
"/data/general/traps/natural_forest.lua",
})
local thieves = {
"rogue",
"rogue sapper",
"thief",
"cutpurse",
"assassin"
}
local rogues = {}
local Birther = require "engine.Birther"
for name, data in pairs(Birther.birth_descriptor_def.class["Rogue"].descriptor_choices.subclass) do
if Birther.birth_descriptor_def.subclass[name] and not Birther.birth_descriptor_def.subclass[name].not_on_random_boss then rogues[#rogues+1] = name end
end
defineTile('g', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=4, random_boss={name_scheme=_t"#rng# the Guard", nb_classes=0, force_classes={(rng.table(rogues))}, loot_quality="store", loot_quantity=1, no_loot_randart=true, loot_unique=true, ai_move="move_complex", rank=3.2}}})
defineTile('G', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=6, random_boss={name_scheme=_t"#rng# the Guard", nb_classes=0, force_classes={(rng.table(rogues))}, loot_quality="store", loot_quantity=1, no_loot_randart=true, loot_unique=true, ai_move="move_complex", rank=3.2}}})
defineTile('r', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=4}})
defineTile('R', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=7}})
defineTile('l', "FLOOR", nil, {random_filter={add_levels=10, name = "bandit lord"}})
defineTile('a', "FLOOR", {random_filter={add_levels=5, tome_mod="vault"}}, nil)
defineTile('$', "FLOOR", {random_filter={add_levels=25, type="money"}})
defineTile('t', "FLOOR", nil, nil, {random_filter={add_levels=20}})
defineTile('j', "FLOOR", {random_filter={add_levels=10, type="jewelry", tome_mod="gvault"}})
defineTile('<', stairs(), nil, {random_filter={name=(rng.table(thieves)), add_levels=6, random_boss={name_scheme=_t"#rng# the Guard", nb_classes=0, force_classes={(rng.table(rogues))}, loot_quality="store", loot_quantity=1, no_loot_randart=true, loot_unique=true, ai_move="move_complex", rank=3.2,
on_die=function(self, who) -- drop lore note on death
local lore = mod.class.Object.new{
type = "lore", subtype="lore",
unided_name = _t"scroll", identified=true,
display = "?", color=colors.ANTIQUE_WHITE, image="object/scroll.png",
encumber = 0,
name = _t"Guard's Journal", lore="bandit-vault-guard",
desc = _t[[A messily scrawled pile of loose papers.]],
level_range = {1, 20},
rarity = false,
}
game.zone:addEntity(game.level, lore, "object", self.x, self.y)
end }}})
return {
[[,,,,,,,,,,,,,fX#######,]],
[[,,###########ff#R$$$R#,]],
[[,,#.$r.l..$.####...G.#,]],
[[,,#jj.......+.t+.....#,]],
[[,,#R$$..$$$R#######+###]],
[[,,#####+######~~#$$...#]],
[[,,,X#....g#~~~~~#<j.rr#]],
[[,,,,#!#####,,,,,#######]],
}
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009 - 2019 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
local Talents = require("engine.interface.ActorTalents")
setStatusAll{no_teleport=true, vault_only_door_open=true, room_map = {can_open=true}}
specialList("actor", {
"/data/general/npcs/thieve.lua",
"/data/general/npcs/minotaur.lua",
"/data/general/npcs/troll.lua",
})
specialList("terrain", {
"/data/general/grids/water.lua",
"/data/general/grids/forest.lua",
}, true)
border = 0
startx = 18
starty = 7
rotates = {"default", "90", "180", "270", "flipx", "flipy"}
local thieves = {
"rogue",
"rogue sapper",
"thief",
"cutpurse",
"assassin"
}
local thugs = {
"bandit",
"mountain troll",
"minotaur"
}
local bosses = {
"bandit lord",
"assassin",
"shadowblade"
}
local thuggeries = {"Berserker", "Bulwark", "Brawler"}
local rogues = {}
local Birther = require "engine.Birther"
for name, data in pairs(Birther.birth_descriptor_def.class["Rogue"].descriptor_choices.subclass) do
if Birther.birth_descriptor_def.subclass[name] and not Birther.birth_descriptor_def.subclass[name].not_on_random_boss then rogues[#rogues+1] = name end
end
defineTile('.', "FLOOR")
defineTile('#', "HARDWALL")
defineTile('+', "DOOR")
defineTile('!', "DOOR_VAULT")
defineTile('>', "DYNAMIC_ZONE_EXIT")
defineTile('*', "FLOOR", nil, nil, {random_filter={add_levels=20}})
defineTile('g', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=3, random_boss={name_scheme=_t"#rng# the Guard", nb_classes=0, force_classes={(rng.table(rogues))}, loot_quality="store", loot_quantity=1, no_loot_randart=true, loot_unique=true, ai_move="move_complex", rank=3.2}}})
defineTile('G', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=5, random_boss={name_scheme=_t"#rng# the Guard", nb_classes=0, force_classes={(rng.table(rogues))}, loot_quality="store", loot_quantity=1, no_loot_randart=true, loot_unique=true, ai_move="move_complex", rank=3.2}}})
defineTile('t', "FLOOR", nil, {random_filter={name=(rng.table(thugs)), add_levels=4, random_boss={name_scheme=_t"#rng# the Thug", nb_classes=0, force_classes={(rng.table(thuggeries))}, loot_quality="store", loot_quantity=1, ai_move="move_complex", rank=3.5}}})
defineTile('T', "FLOOR", nil, {random_filter={name=(rng.table(thugs)), add_levels=6, random_boss={name_scheme=_t"#rng# the Thug", nb_classes=0, force_classes={(rng.table(thuggeries))}, loot_quality="store", loot_quantity=1, ai_move="move_complex", rank=3.5}}})
defineTile('r', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=2}})
defineTile('R', "FLOOR", nil, {random_filter={name=(rng.table(thieves)), add_levels=3}})
defineTile('l', "FLOOR", nil, {random_filter={add_levels=10, name = "bandit lord"}})
defineTile('i', "FLOOR", nil, {random_filter={name=(rng.table(thugs)), add_levels=3}})
defineTile('I', "FLOOR", nil, {random_filter={name=(rng.table(thugs)), add_levels=6}})
defineTile('B', "FLOOR", nil, {random_filter={name=(rng.table(bosses)), add_levels=8, random_boss={name_scheme=_t"Bandit Leader #rng#", nb_classes=0, force_classes={(rng.table(rogues)), (rng.table(thuggeries))}, loot_quality="store", loot_quantity=1, loot_unique=true, ai_move="move_complex", rank=4,
on_die=function(self, who) -- drop lore note on death
local lore = mod.class.Object.new{
type = "lore", subtype="lore",
unided_name = _t"scroll", identified=true,
display = "?", color=colors.ANTIQUE_WHITE, image="object/scroll.png",
encumber = 0,
name = _t"Boss's Journal", lore="bandit-vault-boss",
desc = _t[[A messily scrawled pile of loose papers.]],
level_range = {1, 20},
rarity = false,
}
game.zone:addEntity(game.level, lore, "object", self.x, self.y)
end}}})
defineTile('$', "FLOOR", {random_filter={add_levels=25, type="money"}})
defineTile('g', "FLOOR", {random_filter={add_levels=25, type="gem"}})
local def = {
[[####################]],
[[#gg#$+*.i..+....$l$#]],
[[#$$$$#+#########R$$#]],
[[#ggg$#I...i+*..#####]],
[[######.I...###...g##]],
[[##ggg#+#####..r...##]],
[[###$##..i.r#..###..#]],
[[##$$+G.....#..RT..>#]],
[[###$##...r.#..###.r#]],
[[##$R$#r....#.R...###]],
[[##iBi##+######....*#]],
[[#######.i..+G..###+#]],
[[##gg$##+##########.#]],
[[##$$$r..####$$rr...#]],
[[##RR..$$####t$$$..R#]],
[[####################]],
}
return def
......@@ -46,7 +46,7 @@ return {
edge_entrances = {4,6},
rooms = {"forest_clearing", {"lesser_vault",8}},
rooms_config = {forest_clearing={pit_chance=5, filters={{type="insect", subtype="ant"}, {type="insect"}, {type="animal", subtype="snake"}, {type="animal", subtype="canine"}}}},
lesser_vaults_list = {"honey_glade", "troll-hideout", "mage-hideout", "thief-hideout", "plantlife", "mold-path", "loot-vault","worms"},
lesser_vaults_list = {"honey_glade", "troll-hideout", "mage-hideout", "thief-hideout", "plantlife", "mold-path", "loot-vault", "worms", "bandit-fortress"},
['.'] = "GRASS",
['#'] = "TREE",
up = "GRASS_UP4",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment