diff options
author | dolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-06-12 03:57:11 +0000 |
---|---|---|
committer | dolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-06-12 03:57:11 +0000 |
commit | a6b399eae4cd72f6bc2f077a694ecf5ef6b75ffc (patch) | |
tree | 5f9ce43c244881192bede86434a5e8382c85fb15 /crawl-ref/source/xom.cc | |
parent | 662e3cb4688c794cfb3294772cc49b96e5311bb8 (diff) | |
download | crawl-ref-a6b399eae4cd72f6bc2f077a694ecf5ef6b75ffc.tar.gz crawl-ref-a6b399eae4cd72f6bc2f077a694ecf5ef6b75ffc.zip |
Overhaul god gift handling again so that we can tell which god sent
which gift. There was an unused god parameter in the monsters struct,
which was probably intended to hold which god a monster worshipped.
I've used it as an indicator of which god sent the monster, under the
assumption that gods would send their own worshippers as gifts. (I hope
this isn't an abuse of it.)
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5748 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/xom.cc')
-rw-r--r-- | crawl-ref/source/xom.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crawl-ref/source/xom.cc b/crawl-ref/source/xom.cc index 8b681c21eb..18de3e6075 100644 --- a/crawl-ref/source/xom.cc +++ b/crawl-ref/source/xom.cc @@ -498,7 +498,7 @@ static bool xom_is_good(int sever) summons[i] = create_monster( mgen_data(mon, BEH_FRIENDLY, 3, - you.pos(), you.pet_target, MG_GOD_GIFT)); + you.pos(), you.pet_target, 0, GOD_XOM)); if (summons[i] != -1) success = true; @@ -587,7 +587,7 @@ static bool xom_is_good(int sever) if (create_monster( mgen_data(mon, beha, 6, - you.pos(), hitting, MG_GOD_GIFT)) != -1) + you.pos(), hitting, 0, GOD_XOM)) != -1) { if (different) god_speaks(GOD_XOM, _get_xom_speech("single holy summon")); @@ -683,7 +683,7 @@ static bool xom_is_good(int sever) if (create_monster( mgen_data(xom_random_demon(sever, one_chance_in(8)), beha, 0, - you.pos(), hitting, MG_GOD_GIFT)) != -1) + you.pos(), hitting, 0, GOD_XOM)) != -1) { if (different) god_speaks(GOD_XOM, _get_xom_speech("single major holy summon")); @@ -849,7 +849,7 @@ static bool xom_is_bad(int sever) // Nasty, but fun. if (one_chance_in(4)) - success = cast_tukimas_dance(100, true, true, true); + success = cast_tukimas_dance(100, GOD_XOM, true, true); else { const int numdemons = @@ -860,7 +860,7 @@ static bool xom_is_bad(int sever) if (create_monster( mgen_data::alert_hostile_at( xom_random_punishment_demon(sever), - you.pos(), 4, MG_GOD_GIFT)) != -1) + you.pos(), 4, 0, GOD_XOM)) != -1) { success = true; } |