From 841912a64cbeb5e4d798a7df3d4c7ee881aaf5fa Mon Sep 17 00:00:00 2001 From: zelgadis Date: Tue, 17 Jun 2008 07:17:37 +0000 Subject: If contaminate_player() makes the player glow when s/he wasn't glowing before then give a "you are contaminated with residual magics" type message instead of "you feel more contaminated with magical energies". git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5916 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/player.cc | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'crawl-ref/source/player.cc') diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc index 86f9a53376..926e99f6bb 100644 --- a/crawl-ref/source/player.cc +++ b/crawl-ref/source/player.cc @@ -4936,10 +4936,7 @@ void contaminate_player(int change, bool controlled, bool status_only) // figure out new level new_level = _get_contamination_level(); - if (new_level >= 1) - learned_something_new(TUT_GLOWING); - - if (status_only) + if (status_only || (new_level >= 1 && old_level == 0)) { if (new_level > 0) { @@ -4958,16 +4955,20 @@ void contaminate_player(int change, bool controlled, bool status_only) (new_level == 3) ? "!" : "."); } } - return; } - - if (new_level != old_level) + else if (new_level != old_level) { mprf((change > 0) ? MSGCH_WARN : MSGCH_RECOVERY, "You feel %s contaminated with magical energies.", (change > 0) ? "more" : "less" ); } + if (new_level >= 1) + learned_something_new(TUT_GLOWING); + + if (status_only) + return; + // Zin doesn't like mutations or mutagenic radiation. if (you.religion == GOD_ZIN) { -- cgit v1.2.3-54-g00ecf