summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/database.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-06-18 17:36:50 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-06-18 17:36:50 +0000
commit50c201eae4fa07d6901dc5632c294660fb1a0745 (patch)
tree01fce245e2693ab4c54ef55d06ffdf89fd035390 /crawl-ref/source/database.cc
parent88b3b611b4a78d557eed9f2266c74bdad2b38cd8 (diff)
downloadcrawl-ref-50c201eae4fa07d6901dc5632c294660fb1a0745.tar.gz
crawl-ref-50c201eae4fa07d6901dc5632c294660fb1a0745.zip
Outsource the tutorial descriptions of skills, and make them searchable
in the database. Apply Zaba's patch to view skills from the skill menu ('m'). The melee, ranged and magic skills currently only have really generic descriptions shamelessly copied from the tutorial. There's a front end function get_skill_description that appends extra information like what types of unarmed attacks the current character is capable of (kicking, clawing, punching, ...) git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5955 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/database.cc')
-rw-r--r--crawl-ref/source/database.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/crawl-ref/source/database.cc b/crawl-ref/source/database.cc
index c64b6b44a0..a700e4d825 100644
--- a/crawl-ref/source/database.cc
+++ b/crawl-ref/source/database.cc
@@ -65,6 +65,7 @@ static TextDB AllDBs[] =
"descript/spells.txt",
"descript/gods.txt",
"descript/branches.txt",
+ "descript/skills.txt",
NULL),
TextDB( "db/randart",
@@ -232,8 +233,8 @@ std::vector<std::string> database_find_keys(DBM *database,
{
std::string key((const char *)dbKey.dptr, dbKey.dsize);
- if (tpat.matches(key) &&
- key.find("__") == std::string::npos
+ if (tpat.matches(key)
+ && key.find("__") == std::string::npos
&& (filter == NULL || !(*filter)(key, "")))
{
matches.push_back(key);