diff options
author | dolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-12-01 18:30:23 +0000 |
---|---|---|
committer | dolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-12-01 18:30:23 +0000 |
commit | 37ffd29a84d48b08c2ef799a271f3ab83202a03a (patch) | |
tree | b38cd8507f2b67cb339ce0879e9a1fc1e58e44f0 /crawl-ref/source/religion.h | |
parent | ae715f40ef49bd3e81a59847cb642bf7b328d3de (diff) | |
download | crawl-ref-37ffd29a84d48b08c2ef799a271f3ab83202a03a.tar.gz crawl-ref-37ffd29a84d48b08c2ef799a271f3ab83202a03a.zip |
Add one more cleanup of protection from harm. Since there's more than
one type of it now, expand god_protects_from_harm() to include the logic
for when certain gods do it. Also, as brought up on crawl-ref-discuss,
make Elyvilon do it both casually and during prayer.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2959 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/religion.h')
-rw-r--r-- | crawl-ref/source/religion.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/crawl-ref/source/religion.h b/crawl-ref/source/religion.h index bce7b64b39..989f2b716a 100644 --- a/crawl-ref/source/religion.h +++ b/crawl-ref/source/religion.h @@ -23,6 +23,15 @@ class actor; class monsters; +enum harm_protection_type +{ + HPT_NONE = 0, + HPT_PRAYING, + HPT_ANYTIME, + HPT_PRAYING_PLUS_ANYTIME, + NUM_HPTS +}; + bool is_priest_god(god_type god); void simple_god_message( const char *event, god_type which_deity = GOD_NO_GOD ); int piety_breakpoint(int i); @@ -47,7 +56,7 @@ int piety_rank(int piety = -1); void offer_items(); bool god_likes_butchery(god_type god); bool god_hates_butchery(god_type god); -bool god_protects_from_harm(god_type god); +harm_protection_type god_protects_from_harm(god_type god, bool actual = true); void god_smites_you(god_type god, kill_method_type death_type, const char *message = NULL); void divine_retribution(god_type god); |