diff options
author | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-01-09 15:45:46 +0000 |
---|---|---|
committer | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-01-09 15:45:46 +0000 |
commit | 1fee14c432c2c4398e04b486c6169dde728c94ab (patch) | |
tree | 27f40bd7fbb320f621165b125e973860df45cbd5 /crawl-ref/source/mon-util.h | |
parent | f2a95ba0d453ba6685ed29201beda8a2f703ab79 (diff) | |
download | crawl-ref-1fee14c432c2c4398e04b486c6169dde728c94ab.tar.gz crawl-ref-1fee14c432c2c4398e04b486c6169dde728c94ab.zip |
First cut at new multilevel resists for monsters, needs a lot of work - suggestions welcome.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@3232 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/mon-util.h')
-rw-r--r-- | crawl-ref/source/mon-util.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/crawl-ref/source/mon-util.h b/crawl-ref/source/mon-util.h index 9aaccb551e..d1fb88cf00 100644 --- a/crawl-ref/source/mon-util.h +++ b/crawl-ref/source/mon-util.h @@ -302,12 +302,20 @@ struct mon_resist_def short bludgeon; mon_resist_def(); - mon_resist_def(int flags, short level = 1); + mon_resist_def(int flags, short level = -100); mon_resist_def operator | (const mon_resist_def &other) const; const mon_resist_def &operator |= (const mon_resist_def &other); + +private: + short get_default_res_level(int resist, short level) const; }; +inline mon_resist_def operator | (int a, const mon_resist_def &b) +{ + return (mon_resist_def(a) | b); +} + typedef mon_resist_def mrd; struct monsterentry |