diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-03-31 07:05:53 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-03-31 07:05:53 +0000 |
commit | 20e25439cad6e0c97716e197bb2dceae731a9d24 (patch) | |
tree | d188c2b097b39976c6084a5619b5668dd823ada4 /crawl-ref/source/command.cc | |
parent | 4f02417442109656263366ffcefd68231a0da7e9 (diff) | |
download | crawl-ref-20e25439cad6e0c97716e197bb2dceae731a9d24.tar.gz crawl-ref-20e25439cad6e0c97716e197bb2dceae731a9d24.zip |
Add some checks to Xom making you cast spells, so you don't attempt to
e.g. cast a branding spell, or a transformation that will fail for
whatever reason. You may still occasionally get a "The spell fizzled"
(or whatever) message but that should be rarer now.
Apply the same fail chances for Detect Items as for Magic Mapping for
fully explored levels, and for low severity make Summon Butterflies more
likely to avoid endless attempts of casting Magic Mapping on fully
explored levels.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9573 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/command.cc')
-rw-r--r-- | crawl-ref/source/command.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/crawl-ref/source/command.cc b/crawl-ref/source/command.cc index 6014528aae..6bcb35072f 100644 --- a/crawl-ref/source/command.cc +++ b/crawl-ref/source/command.cc @@ -1371,6 +1371,7 @@ static bool _do_description(std::string key, std::string type, if (thing_created != NON_ITEM && (type == "item" || type == "spell")) { + char name[80]; strncpy(name, key.c_str(), sizeof(name)); if (get_item_by_name(&mitm[thing_created], name, OBJ_WEAPONS)) |