diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-07-18 17:56:33 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-07-18 17:56:33 +0000 |
commit | 468034182154a782ee368da983882595b50de550 (patch) | |
tree | 9a908659d8f5100443b09c0f2e85512271c94a61 /crawl-ref/source/food.cc | |
parent | d6ed0679ee7d39d2bf597cbe92e4aebbcf2d0793 (diff) | |
download | crawl-ref-468034182154a782ee368da983882595b50de550.tar.gz crawl-ref-468034182154a782ee368da983882595b50de550.zip |
Apply my commits r6601, r6604 and r6605 to the 0.4 branch, excluding
purely cosmetic changes.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/branches/stone_soup-0.4@6606 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/food.cc')
-rw-r--r-- | crawl-ref/source/food.cc | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/crawl-ref/source/food.cc b/crawl-ref/source/food.cc index c1b4d0d9c3..e160412b89 100644 --- a/crawl-ref/source/food.cc +++ b/crawl-ref/source/food.cc @@ -314,7 +314,8 @@ static bool _prepare_butchery(bool can_butcher, bool removed_gloves, return (true); } -static bool _butcher_corpse(int corpse_id, bool force_butcher = false) +static bool _butcher_corpse(int corpse_id, bool first_corpse = true, + bool force_butcher = false) { ASSERT(corpse_id != -1); @@ -336,6 +337,10 @@ static bool _butcher_corpse(int corpse_id, bool force_butcher = false) you.religion); } + // Start work on the first corpse we butcher. + if (first_corpse) + mitm[corpse_id].plus2++; + int work_req = 4 - mitm[corpse_id].plus2; if (work_req < 0) work_req = 0; @@ -546,7 +551,7 @@ bool butchery(int which_corpse) { return (false); } - success = _butcher_corpse(corpse_id); + success = _butcher_corpse(corpse_id, true); _terminate_butchery(wpn_switch, removed_gloves, old_weapon, old_gloves); // Remind player of corpses in pack that could be butchered or @@ -561,6 +566,7 @@ bool butchery(int which_corpse) bool bottle_all = false; // for Vampires bool force_butcher = false; bool repeat_prompt = false; + bool first_corpse = true; int keyin; for (stack_iterator si(you.pos()); si; ++si) { @@ -654,8 +660,11 @@ bool butchery(int which_corpse) if (corpse_id != -1) { - if (_butcher_corpse(corpse_id, force_butcher || butcher_all)) + if (_butcher_corpse(corpse_id, first_corpse, + force_butcher || butcher_all)) + { success = true; + } if (!butcher_all && !bottle_all) break; |