summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/spl-book.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-06-04 19:20:31 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-06-04 19:20:31 +0000
commited6970cf64309f5b1741304aa1c828cc0319b00d (patch)
tree831fa8aa26bc8708c24e4c1ff6035bc300ab3852 /crawl-ref/source/spl-book.cc
parent93317003f5a6b3c137990e1a0b44643510b39b28 (diff)
downloadcrawl-ref-ed6970cf64309f5b1741304aa1c828cc0319b00d.tar.gz
crawl-ref-ed6970cf64309f5b1741304aa1c828cc0319b00d.zip
Add various fixes to the new spell memorization messages.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9890 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/spl-book.cc')
-rw-r--r--crawl-ref/source/spl-book.cc32
1 files changed, 19 insertions, 13 deletions
diff --git a/crawl-ref/source/spl-book.cc b/crawl-ref/source/spl-book.cc
index 39db6c5a9a..8f44dad1f7 100644
--- a/crawl-ref/source/spl-book.cc
+++ b/crawl-ref/source/spl-book.cc
@@ -1334,7 +1334,7 @@ static std::vector<spell_type> _get_mem_list()
if (spells_in_book == 0)
{
- mprf(MSGCH_ERROR, "Spellbook \"%s\" contains no spells! Please "
+ mprf(MSGCH_ERROR, "Spellbook \"%s\" contains no spells! Please "
"file a bug report.", book.name(DESC_PLAIN).c_str());
book_errors = true;
}
@@ -1413,48 +1413,54 @@ static std::vector<spell_type> _get_mem_list()
if (num_memable)
return (mem_spells);
- // No spells to be memorized is indicated by an empty list.
+ // No spells to be memorised is indicated by an empty list.
mem_spells.clear();
- // None of the spells can be memorized, tell the player why.
+ // None of the spells can be memorised; tell the player why.
std::string prefix =
- make_stringf("You cannot memorize any new spells. Out of %u "
- "available spells ", all_spells.size());
+ make_stringf("You cannot memorise any new spells. Out of %u "
+ "available spells, ", all_spells.size());
std::vector<std::string> causes;
if (num_known)
- causes.push_back(make_stringf("you already known %u of them",
+ {
+ causes.push_back(make_stringf("you already know %u of them",
num_known));
+ }
if (num_race)
{
- causes.push_back(make_stringf("%u cannot be memorized because of "
+ causes.push_back(make_stringf("%u cannot be memorised because of "
"your race", num_race));
}
if (num_low_xl)
{
- causes.push_back(make_stringf("%u cannot be memorized because of "
- "your low experinece level",
+ causes.push_back(make_stringf("%u cannot be memorised because of "
+ "your low experience level",
num_low_xl));
}
if (num_low_levels)
{
- causes.push_back(make_stringf("%u cannot be memorized because you "
+ causes.push_back(make_stringf("%u cannot be memorised because you "
"don't have enough free spell levels",
num_low_levels));
}
unsigned int total = num_known + num_race + num_low_xl + num_low_levels;
if (total < all_spells.size())
+ {
causes.push_back(make_stringf("%u cannot be accounted for (please "
"file a bug report)",
all_spells.size() - total));
+ }
- mpr_comma_separated_list(prefix, causes, ", and ", ", ", MSGCH_PROMPT);
+ mpr_comma_separated_list(prefix, causes, " and ", ", ", MSGCH_PROMPT);
if (num_unreadable)
- mprf(MSGCH_PROMPT, "Additionally, %d of your spellbooks are beyond "
+ {
+ mprf(MSGCH_PROMPT, "Additionally, %u of your spellbooks are beyond "
"your current level of understanding, and thus none of the "
- "spells in them are avaible to you.");
+ "spells in them are available to you.", num_unreadable);
+ }
return (mem_spells);
}