summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/spl-cast.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-06-11 09:21:36 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-06-11 09:21:36 +0000
commit9bf1ac53d17a3d206fcc21b064208b68c86645b6 (patch)
tree4eef9233b3864a9e56eb1b4d1a599ef7be32aba3 /crawl-ref/source/spl-cast.cc
parent589963865e1c068acfac4616ee626afa18a0cb09 (diff)
downloadcrawl-ref-9bf1ac53d17a3d206fcc21b064208b68c86645b6.tar.gz
crawl-ref-9bf1ac53d17a3d206fcc21b064208b68c86645b6.zip
* Add SDL licence, update docs (yet again).
* Add range flash to 'z'. * Default HISCORE_WEAPON_DETAIL to true. * Rename CREDITS to CREDITS.txt to make it more accessible to Windows users. :p I guess changes.stone_soup should also be renamed, maybe to changelog.txt. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/branches/stone_soup-0.5@9956 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/spl-cast.cc')
-rw-r--r--crawl-ref/source/spl-cast.cc10
1 files changed, 9 insertions, 1 deletions
diff --git a/crawl-ref/source/spl-cast.cc b/crawl-ref/source/spl-cast.cc
index a140fb30d2..48b22f577a 100644
--- a/crawl-ref/source/spl-cast.cc
+++ b/crawl-ref/source/spl-cast.cc
@@ -742,7 +742,15 @@ bool cast_a_spell(bool check_range)
if (check_range && _spell_no_hostile_in_range(spell, minRange))
{
- mpr("There are no visible monsters within range! (Use <w>Z</w> to cast anyway.)");
+ // Abort if there are no hostiles within range, but flash the range
+ // markers for about half a second.
+ Options.target_range = _calc_spell_range(spell);
+ viewwindow(true, false);
+ mpr("There are no visible monsters within range! (Use <w>Z</w> to "
+ "cast anyway.)");
+ delay(500);
+ Options.target_range = 0;
+ viewwindow(true, false);
return (false);
}