summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/describe.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-07-27 21:29:46 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-07-27 21:29:46 +0000
commited2216e8f9a93c5ba091659fd5e4ee5750187e80 (patch)
tree7b9d050f00d0d608ace9c00303e29a5501f30605 /crawl-ref/source/describe.cc
parentabceff13c3921aa10542fb3079abb3ba113ece41 (diff)
downloadcrawl-ref-ed2216e8f9a93c5ba091659fd5e4ee5750187e80.tar.gz
crawl-ref-ed2216e8f9a93c5ba091659fd5e4ee5750187e80.zip
Fix 2028969: excess comma in autoinscriptions of brand-only artefacts.
Also: Tweak inscription prompt. Fix 2027600: Don't prompt when attacking with inappropriate weapon while confused. Fix 2027328: Throwing projectiles at enslaved monsters. When saccing to Nemelex, count chunks and !blood like corpses (deck of summoning rather than wonder). Chunks used to be ignored completely but since they're just chopped up corpses and corpses are worth much more than 4 per piece I don't think it hurts. (Rotten chunks have a value of zero.) Also, decrease !blood price to that of !porridge and lower. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6700 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/describe.cc')
-rw-r--r--crawl-ref/source/describe.cc42
1 files changed, 24 insertions, 18 deletions
diff --git a/crawl-ref/source/describe.cc b/crawl-ref/source/describe.cc
index 8e42a94f09..eeadefbbd3 100644
--- a/crawl-ref/source/describe.cc
+++ b/crawl-ref/source/describe.cc
@@ -315,7 +315,7 @@ static std::vector<std::string> _randart_propnames( const item_def& item )
&& item_ident(item, ISFLAG_KNOW_PROPERTIES))
{
const std::string type = jewellery_base_ability_string(item.sub_type);
- if ( !type.empty() )
+ if (!type.empty())
propnames.push_back(type);
}
else if (item.base_type == OBJ_WEAPONS
@@ -324,22 +324,23 @@ static std::vector<std::string> _randart_propnames( const item_def& item )
std::string ego = weapon_brand_name(item, true);
if (!ego.empty())
{
- // ugly hack to remove the brackets...
- ego = ego.substr(2, ego.length()-3);
+ // XXX: Ugly hack to remove the brackets...
+ ego = ego.substr(2, ego.length() - 3);
- // and another one for adding a comma if needed
- for ( unsigned i = 0; i < ARRAYSZ(propanns); ++i )
- if (known_proprt(propanns[i].prop))
- {
- ego += ",";
- break;
- }
+ // ... and another one for adding a comma if needed.
+ for (unsigned i = 0; i < ARRAYSZ(propanns); ++i)
+ if (known_proprt(propanns[i].prop)
+ && propanns[i].prop != RAP_BRAND)
+ {
+ ego += ",";
+ break;
+ }
propnames.push_back(ego);
}
}
- for ( unsigned i = 0; i < ARRAYSZ(propanns); ++i )
+ for (unsigned i = 0; i < ARRAYSZ(propanns); ++i)
{
if (known_proprt(propanns[i].prop))
{
@@ -2089,22 +2090,27 @@ void inscribe_item(item_def &item, bool proper_prompt)
// existing inscription become an option.
if (!proper_prompt || need_autoinscribe || is_inscribed)
{
- prompt = (is_inscribed ? "Add to inscription? "
- : "Inscribe item? ");
+ prompt = "Press (i) to ";
+ prompt += (is_inscribed ? "add to inscription"
+ : "inscribe");
if (need_autoinscribe || is_inscribed)
{
- prompt += "(You may also ";
+ if (!need_autoinscribe || !is_inscribed)
+ prompt += " or ";
+ else
+ prompt += ", ";
+
if (need_autoinscribe)
{
- prompt += "(a)utoinscribe";
+ prompt += "(a) to autoinscribe";
if (is_inscribed)
prompt += ", or ";
}
if (is_inscribed)
- prompt += "(c)lear it";
- prompt += ".) ";
+ prompt += "(c) to clear it";
}
+ prompt += ". ";
if (proper_prompt)
mpr(prompt.c_str(), MSGCH_PROMPT);
@@ -2897,7 +2903,7 @@ static void _detailed_god_description(god_type which_god)
" decks of Destruction -- weapons and ammunition" EOL
" decks of Dungeons -- jewellery, books, "
"miscellaneous items" EOL
- " decks of Summoning -- corpses" EOL
+ " decks of Summoning -- corpses, chunks, blood" EOL
" decks of Wonders -- consumables: food, potions, "
"scrolls, wands" EOL;
}