summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/player.cc
diff options
context:
space:
mode:
authorNicholas Feinberg <pleasingfung@gmail.com>2014-07-16 23:03:03 -0700
committerNicholas Feinberg <pleasingfung@gmail.com>2014-07-23 22:53:32 -0700
commitbc4cca05f1829bd4bb812008c01682b204ee4975 (patch)
tree51c83a2c6429ab4b2de55d416ea2ab293f16f8c4 /crawl-ref/source/player.cc
parentb26780ba51a322670314796f630ee78383294f54 (diff)
downloadcrawl-ref-bc4cca05f1829bd4bb812008c01682b204ee4975.tar.gz
crawl-ref-bc4cca05f1829bd4bb812008c01682b204ee4975.zip
Put heavily drained players out of their misery
Draining is now limited, based on your level. If you get drained further when you're already very heavily drained, you take very sizeable amounts of damage. Hopefully this will kill you. The death messaging seems to work, but it's not ideal. Possibly someone can adjust that.
Diffstat (limited to 'crawl-ref/source/player.cc')
-rw-r--r--crawl-ref/source/player.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc
index 849f7b46f7..ad89300f1d 100644
--- a/crawl-ref/source/player.cc
+++ b/crawl-ref/source/player.cc
@@ -7213,7 +7213,9 @@ bool player::rot(actor *who, int amount, int immediate, bool quiet)
bool player::drain_exp(actor *who, bool quiet, int pow)
{
- return ::drain_exp(!quiet, pow);
+ return drain_player(pow, who ? who->mindex() : -1,
+ who ? who->name(DESC_A, true).c_str() : NULL,
+ !quiet);
}
void player::confuse(actor *who, int str)