diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-07-20 18:07:51 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-07-20 18:07:51 +0000 |
commit | 3a83e92a99ce7a161f36e0bd2f1412580ef9bca0 (patch) | |
tree | fd7ccbbc3c039f7dac530a0822797913e6dbb7cc /crawl-ref/source/itemprop.cc | |
parent | 0bcbd855b8b1b0a9291aa6b78f2785ffc9987dce (diff) | |
download | crawl-ref-3a83e92a99ce7a161f36e0bd2f1412580ef9bca0.tar.gz crawl-ref-3a83e92a99ce7a161f36e0bd2f1412580ef9bca0.zip |
Apply caotto's plant god patch, for now named "Feawn".
Also fix potions of porridge's menu colour being yellow for Mummies.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@10355 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/itemprop.cc')
-rw-r--r-- | crawl-ref/source/itemprop.cc | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/crawl-ref/source/itemprop.cc b/crawl-ref/source/itemprop.cc index d2372d11a1..3a152f679d 100644 --- a/crawl-ref/source/itemprop.cc +++ b/crawl-ref/source/itemprop.cc @@ -2331,6 +2331,30 @@ bool can_cut_meat(const item_def &item) return (does_damage_type(item, DAM_SLICE)); } +bool is_fruit(const item_def & item) +{ + if(item.base_type != OBJ_FOOD) + return false; + + switch (item.sub_type) + { + case FOOD_APPLE: + case FOOD_APRICOT: + case FOOD_BANANA: + case FOOD_CHOKO: + case FOOD_GRAPE: + case FOOD_LEMON: + case FOOD_LYCHEE: + case FOOD_ORANGE: + case FOOD_PEAR: + case FOOD_RAMBUTAN: + case FOOD_STRAWBERRY: + case FOOD_SULTANA: + return true; + }; + + return false; +} bool food_is_rotten(const item_def &item) { return (item.special < 100) && (item.base_type == OBJ_CORPSES |