summaryrefslogtreecommitdiffstats
path: root/crawl-ref
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref')
-rw-r--r--crawl-ref/source/food.cc9
-rw-r--r--crawl-ref/source/message.cc3
-rw-r--r--crawl-ref/source/religion.cc24
-rw-r--r--crawl-ref/source/religion.h2
4 files changed, 30 insertions, 8 deletions
diff --git a/crawl-ref/source/food.cc b/crawl-ref/source/food.cc
index 749b74d29e..0d2bc1e714 100644
--- a/crawl-ref/source/food.cc
+++ b/crawl-ref/source/food.cc
@@ -302,8 +302,7 @@ bool butchery(void)
mpr("You start hacking away.");
if (you.duration[DUR_PRAYER] &&
- (you.religion == GOD_OKAWARU || you.religion == GOD_MAKHLEB ||
- you.religion == GOD_TROG))
+ god_likes_butchery(you.religion))
{
offer_corpse(objl);
destroy_item(objl);
@@ -315,6 +314,12 @@ bool butchery(void)
work_req = 0;
start_delay(DELAY_BUTCHER, work_req, objl, mitm[objl].special);
+
+ if (you.duration[DUR_PRAYER]
+ && god_hates_butchery(you.religion))
+ {
+ did_god_conduct(DID_DEDICATED_BUTCHERY, 10);
+ }
}
}
diff --git a/crawl-ref/source/message.cc b/crawl-ref/source/message.cc
index 76234468e6..b0a1e98159 100644
--- a/crawl-ref/source/message.cc
+++ b/crawl-ref/source/message.cc
@@ -354,7 +354,8 @@ void mprf( int channel, const char *format, ... )
{
va_list argp;
va_start( argp, format );
- do_message_print( channel, 0, format, argp );
+ do_message_print( channel, channel == MSGCH_GOD? you.religion : 0,
+ format, argp );
va_end( argp );
}
diff --git a/crawl-ref/source/religion.cc b/crawl-ref/source/religion.cc
index 9e7cc8db15..73c8efd006 100644
--- a/crawl-ref/source/religion.cc
+++ b/crawl-ref/source/religion.cc
@@ -1087,6 +1087,9 @@ bool did_god_conduct( int thing_done, int level )
{
case GOD_KIKUBAAQUDGHA:
case GOD_YREDELEMNUL:
+ case GOD_VEHUMET:
+ case GOD_MAKHLEB:
+ case GOD_LUGONU:
simple_god_message(" accepts your slave's kill.");
ret = true;
if (random2(level + 10 - you.experience_level/3) > 5)
@@ -2151,7 +2154,7 @@ void offer_items()
case GOD_OKAWARU:
case GOD_MAKHLEB:
case GOD_NEMELEX_XOBEH:
- mprf("%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
+ mprf(MSGCH_GOD, "%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
sacrifice_message(you.religion, mitm[i]).c_str());
#ifdef DEBUG_DIAGNOSTICS
@@ -2169,7 +2172,7 @@ void offer_items()
break;
case GOD_SIF_MUNA:
- mprf("%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
+ mprf(MSGCH_GOD, "%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
sacrifice_message(you.religion, mitm[i]).c_str());
if (value >= 150)
@@ -2183,7 +2186,7 @@ void offer_items()
if (mitm[i].base_type != OBJ_CORPSES)
break;
- mprf("%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
+ mprf(MSGCH_GOD, "%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
sacrifice_message(you.religion, mitm[i]).c_str());
gain_piety(1);
@@ -2197,7 +2200,7 @@ void offer_items()
break;
}
- mprf("%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
+ mprf(MSGCH_GOD, "%s%s", mitm[i].name(DESC_CAP_THE).c_str(),
sacrifice_message(you.religion, mitm[i]).c_str());
if (random2(value) >= random2(50)
@@ -2313,9 +2316,20 @@ void god_pitch(god_type which_god)
redraw_skill( you.your_name, player_title() );
} // end god_pitch()
+bool god_likes_butchery(god_type god)
+{
+ return (you.religion == GOD_OKAWARU || you.religion == GOD_MAKHLEB ||
+ you.religion == GOD_TROG || you.religion == GOD_LUGONU);
+}
+
+bool god_hates_butchery(god_type god)
+{
+ return (god == GOD_ELYVILON);
+}
+
void offer_corpse(int corpse)
{
- mprf("%s%s", mitm[corpse].name(DESC_CAP_THE).c_str(),
+ mprf(MSGCH_GOD, "%s%s", mitm[corpse].name(DESC_CAP_THE).c_str(),
sacrifice_message(you.religion, mitm[corpse]).c_str());
did_god_conduct(DID_DEDICATED_BUTCHERY, 10);
diff --git a/crawl-ref/source/religion.h b/crawl-ref/source/religion.h
index 02c85d2494..208f57b9bf 100644
--- a/crawl-ref/source/religion.h
+++ b/crawl-ref/source/religion.h
@@ -34,6 +34,8 @@ int god_colour(god_type god);
void god_pitch(god_type which_god);
int piety_rank(int piety = -1);
void offer_items();
+bool god_likes_butchery(god_type god);
+bool god_hates_butchery(god_type god);
bool xom_is_nice();
void xom_is_stimulated(int maxinterestingness);