diff options
author | Brendan Hickey <brendan@bhickey.net> | 2013-07-28 00:31:07 -0700 |
---|---|---|
committer | Brendan Hickey <brendan@bhickey.net> | 2013-07-28 00:37:53 -0700 |
commit | cc0fb03b9eee93cd3fbfb7b9ea40c8b1bfa7a872 (patch) | |
tree | 2534d2f5cac007ec674bc966576f0d47542d17b0 /crawl-ref/source/shout.cc | |
parent | 772cbec2479d6b59ccb91cad149c7edf8968cf6f (diff) | |
download | crawl-ref-cc0fb03b9eee93cd3fbfb7b9ea40c8b1bfa7a872.tar.gz crawl-ref-cc0fb03b9eee93cd3fbfb7b9ea40c8b1bfa7a872.zip |
Refactor 'you.religion' checks.
Pull 'you.religion [!=]= FOO' checks into a function: you_worship(FOO).
This change is part of a large plan to clean up religion.
Diffstat (limited to 'crawl-ref/source/shout.cc')
-rw-r--r-- | crawl-ref/source/shout.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crawl-ref/source/shout.cc b/crawl-ref/source/shout.cc index 480385fa0b..aa2d4c0d02 100644 --- a/crawl-ref/source/shout.cc +++ b/crawl-ref/source/shout.cc @@ -419,7 +419,7 @@ void item_noise(const item_def &item, string msg, int loudness) // replace references to player name and god msg = replace_all(msg, "@player_name@", you.your_name); msg = replace_all(msg, "@player_god@", - you.religion == GOD_NO_GOD ? "atheism" + you_worship(GOD_NO_GOD) ? "atheism" : god_name(you.religion, coinflip())); msg = replace_all(msg, "@a_player_genus@", article_a(species_name(you.species, true))); |