diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-04-20 09:37:00 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-04-20 09:37:00 +0000 |
commit | bb3b8b8286b84de95546d1121d0c305bbdc85851 (patch) | |
tree | c56eaeeca56855ac86631fa37b2b3128784f7fc1 /crawl-ref/source/item_use.cc | |
parent | 6452e938ce43d8447bba63a5fcfbaee5e4673baa (diff) | |
download | crawl-ref-bb3b8b8286b84de95546d1121d0c305bbdc85851.tar.gz crawl-ref-bb3b8b8286b84de95546d1121d0c305bbdc85851.zip |
* Fix non-prompting when firing through allies.
* Don't autopickup chunks if starving.
(Yes, I died because of that. Xom was very much amused...)
* Some spacing fixes.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9668 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/item_use.cc')
-rw-r--r-- | crawl-ref/source/item_use.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/crawl-ref/source/item_use.cc b/crawl-ref/source/item_use.cc index 9e57ea98e6..19d7fda3af 100644 --- a/crawl-ref/source/item_use.cc +++ b/crawl-ref/source/item_use.cc @@ -2360,6 +2360,11 @@ bool throw_it(bolt &pbolt, int throw_2, bool teleport, int acc_bonus, // Don't do the tracing when using Portaled Projectile, or when confused. if (!teleport && !you.confused()) { + // Set values absurdly high to make sure the tracer will + // complain if we're attempting to fire through allies. + pbolt.hit = 100; + pbolt.damage = dice_def(1, 100); + // Init tracer variables. pbolt.foe_info.reset(); pbolt.friend_info.reset(); @@ -2378,6 +2383,8 @@ bool throw_it(bolt &pbolt, int throw_2, bool teleport, int acc_bonus, delete pbolt.special_explosion; return (false); } + pbolt.hit = 0; + pbolt.damage = dice_def(); } pbolt.is_tracer = false; |