Attached Files |
sustain-abilities.patch [^] (1,279 bytes) 2013-12-29 05:24 [Show Content] [Hide Content]From a6a5386c8bd5f5b0d063afc3a60061905b242083 Mon Sep 17 00:00:00 2001
From: Sage <SageBasilMint@gmail.com>
Date: Fri, 27 Dec 2013 22:46:34 +0000
Subject: [PATCH] Add an indicator and identify sustain abilities on partial
protection.
---
crawl-ref/source/player-stats.cc | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/crawl-ref/source/player-stats.cc b/crawl-ref/source/player-stats.cc
index 0bf1af0..a25ca2f 100644
--- a/crawl-ref/source/player-stats.cc
+++ b/crawl-ref/source/player-stats.cc
@@ -521,7 +521,7 @@ bool lose_stat(stat_type which_stat, int stat_loss, bool force,
int sust = player_sust_abil();
stat_loss >>= sust;
- if (sust && !stat_loss && !player_sust_abil(false))
+ if (sust && !player_sust_abil(false))
{
item_def *ring = get_only_unided_ring();
if (ring && !is_artefact(*ring)
@@ -533,7 +533,8 @@ bool lose_stat(stat_type which_stat, int stat_loss, bool force,
}
mprf(stat_loss > 0 ? MSGCH_WARN : MSGCH_PLAIN,
- "You feel %s%s.",
+ "You feel %s%s%s.",
+ stat_loss > 0 && player_sust_abil(false) ? "somewhat " : "",
stat_desc(which_stat, SD_LOSS),
stat_loss > 0 ? "" : " for a moment");
--
1.7.9.5
|